[gmime] Fixed parameter list parsing logic to not report a warning when everything is valid
- From: Rico Tzschichholz <ricotz src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gmime] Fixed parameter list parsing logic to not report a warning when everything is valid
- Date: Thu, 10 Sep 2020 14:27:43 +0000 (UTC)
commit e83530afd378b6c913d7bbe614e41cc4eb4ad62f
Author: Jeffrey Stedfast <jestedfa microsoft com>
Date: Sun May 24 16:48:42 2020 -0400
Fixed parameter list parsing logic to not report a warning when everything is valid
gmime/gmime-param.c | 7 +++++--
gmime/gmime-parser.c | 2 +-
2 files changed, 6 insertions(+), 3 deletions(-)
---
diff --git a/gmime/gmime-param.c b/gmime/gmime-param.c
index ca419d25..238b2990 100644
--- a/gmime/gmime-param.c
+++ b/gmime/gmime-param.c
@@ -1335,9 +1335,12 @@ decode_param_list (GMimeParserOptions *options, const char *in, gint64 offset)
t = (struct _rfc2184_param *) &list;
rfc2184_hash = g_hash_table_new (g_mime_strcase_hash, g_mime_strcase_equal);
- skip_cfws (&inptr);
-
do {
+ skip_cfws (&inptr);
+
+ if (*inptr == '\0')
+ break;
+
/* invalid format? */
if (!decode_param (options, &inptr, &name, &value, &id, &rfc2047_charset, &encoded, &method,
offset)) {
skip_cfws (&inptr);
diff --git a/gmime/gmime-parser.c b/gmime/gmime-parser.c
index b8eb64e4..a116036c 100644
--- a/gmime/gmime-parser.c
+++ b/gmime/gmime-parser.c
@@ -2010,7 +2010,7 @@ parser_scan_multipart_subparts (GMimeParser *parser, GMimeParserOptions *options
break;
}
- /* This part has no content, but that will be handled in in
parser_construct_multipart()
+ /* This part has no content, but that will be handled in parser_construct_multipart()
* or parser_consruct_leaf_part(). */
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]