summaryrefslogtreecommitdiff
path: root/eel/eel-string.c
diff options
context:
space:
mode:
authorPablo Barciela <[email protected]>2019-03-31 03:47:38 +0200
committerraveit65 <[email protected]>2022-07-19 23:33:41 +0200
commitf9da15db10e31c9e1569c105adc29cf80aaf4811 (patch)
tree35ae38088aaa21b66fdab3357696e1beab41bd8d /eel/eel-string.c
parent23dcbd3168fc0aec25c018ffc1091f9440a38a95 (diff)
downloadcaja-f9da15db10e31c9e1569c105adc29cf80aaf4811.tar.bz2
caja-f9da15db10e31c9e1569c105adc29cf80aaf4811.tar.xz
eel-string: Use 'va_copy' instead of 'G_VA_COPY'
Fixes cppcheck warnings: [eel-string.c:681]: (error) va_list 'va' used before va_start() was called. [eel-string.c:682]: (error) va_list 'va' used before va_start() was called. [eel-string.c:683]: (error) va_list 'va' used before va_start() was called. [eel-string.c:684]: (error) va_list 'va' used before va_start() was called. [eel-string.c:697]: (error) va_list 'va' used before va_start() was called. [eel-string.c:698]: (error) va_list 'va' used before va_start() was called. [eel-string.c:699]: (error) va_list 'va' used before va_start() was called. [eel-string.c:700]: (error) va_list 'va' used before va_start() was called. [eel-string.c:709]: (error) va_list 'va' used before va_start() was called. [eel-string.c:710]: (error) va_list 'va' used before va_start() was called. [eel-string.c:714]: (error) va_list 'va' used before va_start() was called. [eel-string.c:720]: (error) va_list 'va' used before va_start() was called. [eel-string.c:722]: (error) va_list 'va' used before va_start() was called.
Diffstat (limited to 'eel/eel-string.c')
-rw-r--r--eel/eel-string.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/eel/eel-string.c b/eel/eel-string.c
index a4202ad8..a4bdb75c 100644
--- a/eel/eel-string.c
+++ b/eel/eel-string.c
@@ -683,7 +683,7 @@ eel_strdup_vprintf_with_custom (EelPrintfHandler *custom,
{
char *val;
- G_VA_COPY(va, va_orig);
+ va_copy (va, va_orig);
skip_to_arg (&va, args, custom, conversions[i].precision_pos);
val = g_strdup_vprintf ("%d", va);
va_end (va);
@@ -699,7 +699,7 @@ eel_strdup_vprintf_with_custom (EelPrintfHandler *custom,
{
char *val;
- G_VA_COPY(va, va_orig);
+ va_copy (va, va_orig);
skip_to_arg (&va, args, custom, conversions[i].width_pos);
val = g_strdup_vprintf ("%d", va);
va_end (va);
@@ -711,7 +711,7 @@ eel_strdup_vprintf_with_custom (EelPrintfHandler *custom,
g_free (val);
}
- G_VA_COPY(va, va_orig);
+ va_copy (va, va_orig);
skip_to_arg (&va, args, custom, conversions[i].arg_pos);
type = args[conversions[i].arg_pos];
if (type < 0)