diff options
author | Rosen Penev <rosenp@gmail.com> | 2020-09-20 00:53:25 -0700 |
---|---|---|
committer | Rosen Penev <rosenp@gmail.com> | 2020-09-20 15:17:05 -0700 |
commit | 8ad058f7610efb01213a4a9bb5427b35a0ec3c83 (patch) | |
tree | 6ef8773588d8623b2f679af6ff67f90b53d11d02 | |
parent | 94d78ce419d37de5874596de8f73f79db90d589e (diff) | |
download | grilo-8ad058f7610efb01213a4a9bb5427b35a0ec3c83.tar.gz |
net: Fix wrong printf format under 32-bit
Found with -Wformat :
In file included from ../src/grilo.h:31,
from ../libs/net/grl-net-wc.c:52:
../libs/net/grl-net-wc.c: In function 'get_url':
../libs/net/grl-net-wc.c:770:16: warning: format '%lu' expects argument
of type 'long unsigned int', but argument 5 has type 'gint64' {aka
'long long int'} [-Wformat=]
770 | GRL_DEBUG ("delaying web request by %lu seconds",
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
771 | priv->last_request - now);
| ~~~~~~~~~~~~~~~~~~~~~~~~
| |
| gint64 {aka long long int}
-rw-r--r-- | libs/net/grl-net-wc.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libs/net/grl-net-wc.c b/libs/net/grl-net-wc.c index 9bd4922..5a8e89f 100644 --- a/libs/net/grl-net-wc.c +++ b/libs/net/grl-net-wc.c @@ -767,7 +767,7 @@ get_url (GrlNetWc *self, } else { priv->last_request += priv->throttling; - GRL_DEBUG ("delaying web request by %lu seconds", + GRL_DEBUG ("delaying web request by %" G_GINT64_FORMAT " seconds", priv->last_request - now); id = g_timeout_add_seconds_full (G_PRIORITY_DEFAULT, priv->last_request - now, |