libmm-common: no need to check for end of string when looking for spaces
This commit is contained in:
@@ -346,7 +346,7 @@ mm_common_parse_key_value_string (const gchar *str,
|
|||||||
gboolean keep_iteration = FALSE;
|
gboolean keep_iteration = FALSE;
|
||||||
|
|
||||||
/* Skip leading spaces */
|
/* Skip leading spaces */
|
||||||
while (*p && g_ascii_isspace (*p))
|
while (g_ascii_isspace (*p))
|
||||||
p++;
|
p++;
|
||||||
|
|
||||||
/* Key start */
|
/* Key start */
|
||||||
@@ -371,7 +371,7 @@ mm_common_parse_key_value_string (const gchar *str,
|
|||||||
}
|
}
|
||||||
|
|
||||||
/* Skip whitespaces, if any */
|
/* Skip whitespaces, if any */
|
||||||
while (*p && g_ascii_isspace (*p))
|
while (g_ascii_isspace (*p))
|
||||||
p++;
|
p++;
|
||||||
|
|
||||||
/* Equal sign must be here */
|
/* Equal sign must be here */
|
||||||
@@ -385,7 +385,7 @@ mm_common_parse_key_value_string (const gchar *str,
|
|||||||
p++;
|
p++;
|
||||||
|
|
||||||
/* Skip whitespaces, if any */
|
/* Skip whitespaces, if any */
|
||||||
while (*p && g_ascii_isspace (*p))
|
while (g_ascii_isspace (*p))
|
||||||
p++;
|
p++;
|
||||||
|
|
||||||
/* Do we have a quote-enclosed string? */
|
/* Do we have a quote-enclosed string? */
|
||||||
@@ -421,7 +421,7 @@ mm_common_parse_key_value_string (const gchar *str,
|
|||||||
/* Note that we allow value == value_end here */
|
/* Note that we allow value == value_end here */
|
||||||
|
|
||||||
/* Skip whitespaces, if any */
|
/* Skip whitespaces, if any */
|
||||||
while (*p && g_ascii_isspace (*p))
|
while (g_ascii_isspace (*p))
|
||||||
p++;
|
p++;
|
||||||
|
|
||||||
/* If a comma is found, we should keep the iteration */
|
/* If a comma is found, we should keep the iteration */
|
||||||
|
Reference in New Issue
Block a user