From 537f8484b7e90f05ae8a9856b35cf823a8b25fe8 Mon Sep 17 00:00:00 2001 From: Guido Draheim Date: Wed, 29 Dec 2010 16:24:35 +0000 Subject: [PATCH] wrap fd.open like in the Fedora patch. --- zzip/file.c | 2 +- zzip/write.c | 2 +- zzip/zip.c | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/zzip/file.c b/zzip/file.c index 83a71f3..5cda62e 100644 --- a/zzip/file.c +++ b/zzip/file.c @@ -771,7 +771,7 @@ zzip_open_shared_io(ZZIP_FILE * stream, { zzip_plugin_io_t os = (o_modes & ZZIP_ALLOWREAL) ? zzip_get_default_io() : io; - int fd = os->fd.open(filename, o_flags); /* io->fd.open */ + int fd = (os->fd.open)(filename, o_flags); /* io->fd.open */ if (fd != -1) { diff --git a/zzip/write.c b/zzip/write.c index d862fe2..7521e20 100644 --- a/zzip/write.c +++ b/zzip/write.c @@ -176,7 +176,7 @@ zzip_dir_creat_ext_io(zzip_char_t * name, int o_mode, memcpy(dir->realname + name_len, exx, exx_len); /* append! */ } ____; - fd = io->fd.open(dir->realname, O_CREAT | O_TRUNC | O_WRONLY, o_mode); + fd = (io->fd.open)(dir->realname, O_CREAT | O_TRUNC | O_WRONLY, o_mode); dir->realname[name_len] = '\0'; /* keep ummodified */ if (fd != -1) { dir->fd = fd; return dir; } diff --git a/zzip/zip.c b/zzip/zip.c index 2eb9f19..a574b24 100644 --- a/zzip/zip.c +++ b/zzip/zip.c @@ -776,7 +776,7 @@ __zzip_try_open(zzip_char_t * filename, int filemode, for (; *ext; ++ext) { strcpy(file + len, *ext); - fd = io->fd.open(file, filemode); + fd = (io->fd.open)(file, filemode); if (fd != -1) return fd; } @@ -811,7 +811,7 @@ zzip_dir_open_ext_io(zzip_char_t * filename, zzip_error_t * e, if (! ext) ext = zzip_get_default_ext(); - fd = io->fd.open(filename, O_RDONLY | O_BINARY); + fd = (io->fd.open)(filename, O_RDONLY | O_BINARY); if (fd != -1) { return zzip_dir_fdopen_ext_io(fd, e, ext, io); -- 2.40.0