summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorErich Eckner <git@eckner.net>2018-10-30 09:57:56 +0100
committerErich Eckner <git@eckner.net>2018-10-31 21:48:36 +0100
commit20c62edc0497bb26794df0ea6f506c59638096b0 (patch)
treec0b64590ab19bae7a25aba11fb00c41b9bf7190f
parent48c4f8df3381cab4f85d479f7567b6d0d6da342d (diff)
downloadanzeige-20c62edc0497bb26794df0ea6f506c59638096b0.tar.xz
input_gadgets.c: add commented direct-file read for debugging
-rw-r--r--input_gadgets.c17
1 files changed, 17 insertions, 0 deletions
diff --git a/input_gadgets.c b/input_gadgets.c
index 98f761f..aad8aad 100644
--- a/input_gadgets.c
+++ b/input_gadgets.c
@@ -359,6 +359,23 @@ char *gadgets_retrieve_weather_warnings(char *output, int max_len)
return NULL;
}
+/* FILE *f = fopen("Z_CAP_C_EDZW_LATEST_PVW_STATUS_PREMIUMDWD_COMMUNEUNION_DE.zip","rb");
+ if (f == NULL) {
+ perror("failed to open file");
+ return NULL;
+ }
+ fseek(f, 0, SEEK_END);
+ chunk.size = ftell(f);
+ chunk.memory = malloc(chunk.size);
+ if (chunk.memory == NULL) {
+ fprintf(stderr, "malloc failed to allocate %d bytes", chunk.size);
+ fclose(f);
+ return NULL;
+ }
+ fseek(f, 0, SEEK_SET);
+ fread(chunk.memory, chunk.size, 1, f);
+ fclose(f); */
+
zip_error_t error;
zip_source_t *src;
zip_t *za;