summaryrefslogtreecommitdiff
path: root/src/user.c
diff options
context:
space:
mode:
authorSimon McVittie <smcv@debian.org>2023-02-07 11:39:29 +0000
committerSimon McVittie <smcv@debian.org>2023-02-07 11:54:33 +0000
commitc142812f7653cd1f6e52224da8410cd09f102a4f (patch)
treee31ae092f7e6304fe0309f1202d97a24cfd828c9 /src/user.c
parenta1a330b8720e4bc1c2154f120196372627dc7b2a (diff)
downloadaccountsservice-c142812f7653cd1f6e52224da8410cd09f102a4f.tar.gz
Annotate varargs functions with G_GNUC_PRINTF
This lets the compiler detect and diagnose type mismatches like the one fixed in the previous commit. Helps: https://gitlab.freedesktop.org/accountsservice/accountsservice/-/issues/109 Signed-off-by: Simon McVittie <smcv@debian.org>
Diffstat (limited to 'src/user.c')
-rw-r--r--src/user.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/user.c b/src/user.c
index 67cbb1b..0a8e586 100644
--- a/src/user.c
+++ b/src/user.c
@@ -1120,6 +1120,11 @@ user_set_saved (User *user,
accounts_user_set_saved (ACCOUNTS_USER (user), saved);
}
+static void throw_error (GDBusMethodInvocation *context,
+ gint error_code,
+ const gchar *format,
+ ...) G_GNUC_PRINTF (3, 4);
+
static void
throw_error (GDBusMethodInvocation *context,
gint error_code,