Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F163244649
D18456.id51667.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
1 KB
Referenced Files
None
Subscribers
None
D18456.id51667.diff
View Options
Index: lib/libz/Symbol.map
===================================================================
--- lib/libz/Symbol.map
+++ lib/libz/Symbol.map
@@ -103,6 +103,10 @@
zopen;
};
+FBSD_1.6 {
+ zdopen;
+};
+
ZLIBprivate_1.0 {
_tr_align;
_tr_flush_block;
Index: lib/libz/Versions.def
===================================================================
--- lib/libz/Versions.def
+++ lib/libz/Versions.def
@@ -15,6 +15,9 @@
FBSD_1.2 {
} ZLIB_1.2.4.0;
+FBSD_1.6 {
+} FBSD_1.2;
+
ZLIBprivate_1.0 {
} ZLIB_1.2.4.0;
Index: lib/libz/zopen.c
===================================================================
--- lib/libz/zopen.c
+++ lib/libz/zopen.c
@@ -9,6 +9,7 @@
#include <zlib.h>
FILE *zopen(const char *fname, const char *mode);
+FILE *zdopen(int fd, const char *mode);
/* convert arguments */
static int
@@ -47,3 +48,18 @@
else
return (funopen(gz, NULL, xgzwrite, xgzseek, xgzclose));
}
+
+FILE *
+zdopen(int fd, const char *mode)
+{
+ gzFile gz;
+
+ gz = gzdopen(fd, mode);
+ if (gz == NULL)
+ return (NULL);
+
+ if (*mode == 'r')
+ return (funopen(gz, xgzread, NULL, xgzseek, xgzclose));
+ else
+ return (funopen(gz, NULL, xgzwrite, xgzseek, xgzclose));
+}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Wed, Jul 22, 9:10 AM (1 h, 40 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
35358580
Default Alt Text
D18456.id51667.diff (1 KB)
Attached To
Mode
D18456: Add zdopen(), for use in capability mode.
Attached
Detach File
Event Timeline
Log In to Comment