From 63728e1340a27b7ae629a747229871f3dc670de5 Mon Sep 17 00:00:00 2001 From: yzrh Date: Tue, 20 Dec 2022 00:05:13 +0000 Subject: Add error message for JBIG. Signed-off-by: yzrh --- src/cnki_pdf.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'src/cnki_pdf.c') diff --git a/src/cnki_pdf.c b/src/cnki_pdf.c index f8a5d44..6a7a317 100644 --- a/src/cnki_pdf.c +++ b/src/cnki_pdf.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020-2021, yzrh + * Copyright (c) 2020-2022, yzrh * * SPDX-License-Identifier: Apache-2.0 */ @@ -600,10 +600,16 @@ cnki_pdf_hn(cnki_t **param) free(dictionary); free(stream); } else if (ret == 1) { + if ((*param)->stat > 2) + printf("Failed\n"); + free(dictionary); pdf_obj_append(&pdf, ids[i], NULL, NULL, NULL, 0); } else { + if ((*param)->stat > 2) + printf("Unsupported format\n"); + free(dictionary); } } -- cgit v1.2.3