diff options
author | graham.gower <graham.gower@e8e0d7a0-c8d9-11dd-a880-a1081c7ac358> | 2009-11-23 21:31:32 (EST) |
---|---|---|
committer | graham.gower <graham.gower@e8e0d7a0-c8d9-11dd-a880-a1081c7ac358> | 2009-11-23 21:31:32 (EST) |
commit | f4296235e3e302b8729de3fdf92fdd742374c68b (patch) | |
tree | 7da306cd2382a668b6040ab17f673920b194acd1 /libopkg | |
parent | b5023b1788eb78b8c1d521e28dd89c540cf92773 (diff) |
There is no need to use a buffer at all.
git-svn-id: http://opkg.googlecode.com/svn/trunk@352 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
Diffstat (limited to 'libopkg')
-rw-r--r-- | libopkg/pkg_extract.c | 14 |
1 files changed, 2 insertions, 12 deletions
diff --git a/libopkg/pkg_extract.c b/libopkg/pkg_extract.c index e1b4018..d9fbdd5 100644 --- a/libopkg/pkg_extract.c +++ b/libopkg/pkg_extract.c @@ -29,20 +29,10 @@ const char *applet_name = "opkg"; int pkg_extract_control_file_to_stream(pkg_t *pkg, FILE *stream) { - char *buffer = deb_extract(pkg->local_filename, stderr, + deb_extract(pkg->local_filename, stream, extract_control_tar_gz - | extract_one_to_buffer, + | extract_to_stdout, /* to stream actually */ NULL, "./control"); - if (buffer == NULL) { - return EINVAL; - } - - if (fputs(buffer, stream) == EOF) { - free(buffer); - return EINVAL; - } - - free(buffer); return 0; } |