The branch main has been updated by bapt:

URL: 
https://cgit.FreeBSD.org/src/commit/?id=c69047ca7526090cc2aa92c57d9f21a77a82fc2e

commit c69047ca7526090cc2aa92c57d9f21a77a82fc2e
Author:     Baptiste Daroussin <[email protected]>
AuthorDate: 2021-02-02 09:07:57 +0000
Commit:     Baptiste Daroussin <[email protected]>
CommitDate: 2021-02-02 09:08:25 +0000

    Revert "diff: eliminate a useless lseek"
    
    This changes breaks when one of the files is stdin
    
    This reverts commit fa977a3b2bb2d0e6c2957b14474c31b58dd3a8e1.
    
    Reported by:    olivier
---
 usr.bin/diff/diffreg.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/usr.bin/diff/diffreg.c b/usr.bin/diff/diffreg.c
index 4c9211510459..1b28281024c6 100644
--- a/usr.bin/diff/diffreg.c
+++ b/usr.bin/diff/diffreg.c
@@ -490,6 +490,7 @@ opentemp(const char *f)
                }
        }
        close(ifd);
+       lseek(ofd, (off_t)0, SEEK_SET);
        return (fdopen(ofd, "r"));
 }
 
_______________________________________________
[email protected] mailing list
https://lists.freebsd.org/mailman/listinfo/dev-commits-src-main
To unsubscribe, send any mail to "[email protected]"

Reply via email to