[pan2] Fix some ISO C++ 11 warnings



commit b8c8c8ef0bd1d7fd37161c61fe2f97f6b44e15f6
Author: Detlef Graef <detlef graef yahoo de>
Date:   Mon Jul 3 16:56:21 2017 +0200

    Fix some ISO C++ 11 warnings

 pan/data-impl/article-filter.cc |    2 +-
 pan/tasks/nntp.cc               |   10 +++++-----
 pan/tasks/task-xover.cc         |    2 +-
 pan/usenet-utils/numbers.cc     |    4 ++--
 4 files changed, 9 insertions(+), 9 deletions(-)
---
diff --git a/pan/data-impl/article-filter.cc b/pan/data-impl/article-filter.cc
index b0380aa..6d12baa 100644
--- a/pan/data-impl/article-filter.cc
+++ b/pan/data-impl/article-filter.cc
@@ -162,7 +162,7 @@ ArticleFilter :: test_article (const Data        & data,
             s += xit->group;
             s += ':';
             char buf[32];
-            g_snprintf (buf, sizeof(buf), "%"G_GUINT64_FORMAT, xit->number);
+            g_snprintf (buf, sizeof(buf), "%" G_GUINT64_FORMAT, xit->number);
             s += buf;
             s += ' ';
           }
diff --git a/pan/tasks/nntp.cc b/pan/tasks/nntp.cc
index bb8037b..624b3db 100644
--- a/pan/tasks/nntp.cc
+++ b/pan/tasks/nntp.cc
@@ -363,7 +363,7 @@ NNTP :: xover (const Quark   & group,
    _listener = l;
 
    enter_group(group);
-   _commands.push_back (build_command ("XOVER %"G_GUINT64_FORMAT"-%"G_GUINT64_FORMAT"\r\n", low, high));
+   _commands.push_back (build_command ("XOVER %" G_GUINT64_FORMAT"-%" G_GUINT64_FORMAT"\r\n", low, high));
    write_next_command ();
 }
 
@@ -376,7 +376,7 @@ NNTP :: xzver (const Quark   & group,
    _listener = l;
 
    enter_group(group);
-   _commands.push_back (build_command ("XZVER %"G_GUINT64_FORMAT"-%"G_GUINT64_FORMAT"\r\n", low, high));
+   _commands.push_back (build_command ("XZVER %" G_GUINT64_FORMAT"-%" G_GUINT64_FORMAT"\r\n", low, high));
    write_next_command ();
 }
 
@@ -417,7 +417,7 @@ NNTP :: article (const Quark     & group,
 
    enter_group(group);
 
-   _commands.push_back (build_command ("ARTICLE %"G_GUINT64_FORMAT"\r\n", article_number));
+   _commands.push_back (build_command ("ARTICLE %" G_GUINT64_FORMAT"\r\n", article_number));
 
    write_next_command ();
 }
@@ -459,7 +459,7 @@ NNTP :: get_headers (const Quark     & group,
 
    enter_group(group);
 
-   _commands.push_back (build_command ("HEAD %"G_GUINT64_FORMAT"\r\n", article_number));
+   _commands.push_back (build_command ("HEAD %" G_GUINT64_FORMAT"\r\n", article_number));
 
    write_next_command ();
 }
@@ -487,7 +487,7 @@ NNTP :: get_body (const Quark     & group,
 
    enter_group(group);
 
-   _commands.push_back (build_command ("BODY %"G_GUINT64_FORMAT"\r\n", article_number));
+   _commands.push_back (build_command ("BODY %" G_GUINT64_FORMAT"\r\n", article_number));
 
    write_next_command ();
 }
diff --git a/pan/tasks/task-xover.cc b/pan/tasks/task-xover.cc
index 88d7b35..f139e11 100644
--- a/pan/tasks/task-xover.cc
+++ b/pan/tasks/task-xover.cc
@@ -391,7 +391,7 @@ TaskXOver::on_nntp_line_process(NNTP * nntp, const StringView & line)
        // if news server doesn't provide an xref, fake one
        char * buf(0);
        if (xref.empty())
-               xref = buf = g_strdup_printf("%s %s:%"G_GUINT64_FORMAT,
+               xref = buf = g_strdup_printf("%s %s:%" G_GUINT64_FORMAT,
                                nntp->_server.c_str(), nntp->_group.c_str(), number);
 
        uint64_t& h(_high[nntp->_server]);
diff --git a/pan/usenet-utils/numbers.cc b/pan/usenet-utils/numbers.cc
index 5ca857f..0bbd152 100644
--- a/pan/usenet-utils/numbers.cc
+++ b/pan/usenet-utils/numbers.cc
@@ -267,9 +267,9 @@ Numbers :: to_string (std::string & str) const
       Range r (*it);
 
       if (r.low == r.high)
-        bytes = g_snprintf (buf, sizeof(buf), "%"G_GUINT64_FORMAT",", r.low);
+        bytes = g_snprintf (buf, sizeof(buf), "%" G_GUINT64_FORMAT",", r.low);
       else
-         bytes = g_snprintf (buf, sizeof(buf), "%"G_GUINT64_FORMAT"-%"G_GUINT64_FORMAT",", r.low, r.high);
+         bytes = g_snprintf (buf, sizeof(buf), "%" G_GUINT64_FORMAT"-%" G_GUINT64_FORMAT",", r.low, r.high);
       temp.append(buf, bytes);
    }
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]