summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPablo Barciela <[email protected]>2019-03-31 03:47:38 +0200
committerZenWalker <[email protected]>2019-04-12 20:39:45 +0200
commit3ceb908a3ba4d113e19ca742556e3accc943ca4e (patch)
treee0611fc621ef728e9dcc31b1b224c1468cf2c558
parent7f96149e64ec03c6e63ee1ee6d486e5bdbf88445 (diff)
downloadcaja-3ceb908a3ba4d113e19ca742556e3accc943ca4e.tar.bz2
caja-3ceb908a3ba4d113e19ca742556e3accc943ca4e.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.
-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 4521d157..5e0a34c4 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)