summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--cqrlogo.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/cqrlogo.c b/cqrlogo.c
index 6153cb7..a822c6d 100644
--- a/cqrlogo.c
+++ b/cqrlogo.c
@@ -94,15 +94,15 @@ int main(int argc, char **argv) {
}
}
- /* print HTTP header */
- printf("Content-Type: image/png\n\n");
-
/* generate PNG data */
if ((png = generate_png(bitmap, CQR_COMMENT|CQR_REFERER|CQR_VERSION|CQR_LIBVERSION, uri)) == NULL) {
fprintf(stderr, "Failed to generate PNG.\n");
return EXIT_FAILURE;
}
+ /* print HTTP header */
+ printf("Content-Type: image/png\n\n");
+
/* write PNG data to stdout */
if (fwrite(png->buffer, png->size, 1, stdout) != 1) {
fprintf(stderr, "Failed writing PNG data to stdout.\n");