From: Tim Kientzle Date: Sun, 24 May 2009 23:03:06 +0000 (-0400) Subject: Include O_BINARY when opening the file here, for consistency. X-Git-Tag: v2.8.0~639 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=a711beab56cb94c6ffe263381744d9afb61281b9;p=thirdparty%2Flibarchive.git Include O_BINARY when opening the file here, for consistency. SVN-Revision: 1101 --- diff --git a/libarchive/archive_read_disk_entry_from_file.c b/libarchive/archive_read_disk_entry_from_file.c index 6e12517b5..6cd967cf3 100644 --- a/libarchive/archive_read_disk_entry_from_file.c +++ b/libarchive/archive_read_disk_entry_from_file.c @@ -102,7 +102,7 @@ archive_read_disk_entry_from_file(struct archive *_a, * open file descriptor which we can use in the subsequent lookups. */ if ((S_ISREG(st->st_mode) || S_ISDIR(st->st_mode))) { if (fd < 0) - fd = open(pathname, O_RDONLY | O_NONBLOCK); + fd = open(pathname, O_RDONLY | O_NONBLOCK | O_BINARY); if (fd >= 0) { unsigned long stflags; int r = ioctl(fd, EXT2_IOC_GETFLAGS, &stflags);