summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/main.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/main.c b/src/main.c
index 3b80e8e..8b80a1f 100644
--- a/src/main.c
+++ b/src/main.c
@@ -26,11 +26,9 @@
#include "gzip.h"
#include "ustar.h"
-#define OPKG_OPK_MAIN_FILE_BUFFER_SIZE_ 8192
-
struct _opkg_opk_main_opk {
FILE *file;
- char file_buffer[OPKG_OPK_MAIN_FILE_BUFFER_SIZE_];
+ char file_buffer[8192];
struct opkg_opk_gzip *outer_gzip;
struct opkg_opk_ustar *outer_ustar;
char *version_buffer;
@@ -45,7 +43,7 @@ _opkg_opk_main_file_read(void *user_data, char **buffer, size_t *size)
struct _opkg_opk_main_opk *opk = user_data;
*buffer = opk->file_buffer;
- *size = fread(opk->file_buffer, 1, OPKG_OPK_MAIN_FILE_BUFFER_SIZE_,
+ *size = fread(opk->file_buffer, 1, sizeof(opk->file_buffer),
opk->file);
if (feof(opk->file)) {
return OPKG_OPK_END;