[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    [tellico/frameworks] src/3rdparty/libcsv: shhh a couple libcsv warnings
From:       Robby Stephenson <robby () periapsis ! org>
Date:       2015-06-01 1:06:38
Message-ID: E1YzEBa-0008KJ-8N () scm ! kde ! org
[Download RAW message or body]

Git commit a89bf4df26a722710c2e772f4ace740fd91aab39 by Robby Stephenson.
Committed on 30/05/2015 at 12:08.
Pushed by rstephenson into branch 'frameworks'.

shhh a couple libcsv warnings

M  +3    -3    src/3rdparty/libcsv/libcsv.c
M  +1    -1    src/3rdparty/libcsv/libcsv.h

http://commits.kde.org/tellico/a89bf4df26a722710c2e772f4ace740fd91aab39

diff --git a/src/3rdparty/libcsv/libcsv.c b/src/3rdparty/libcsv/libcsv.c
index c7ccc39..f527a30 100644
--- a/src/3rdparty/libcsv/libcsv.c
+++ b/src/3rdparty/libcsv/libcsv.c
@@ -17,7 +17,7 @@ License along with this library; if not, write to the Free Software
 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
 */
 
-#if ___STDC_VERSION__ >= 199901L
+#if defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
 #  include <stdint.h>
 #else
 #  define SIZE_MAX ((size_t)-1) /* C89 doesn't have stdint.h or SIZE_MAX */
@@ -68,7 +68,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  \
02110-1301  USA  
 #define SUBMIT_CHAR(p, c) ((p)->entry_buf[entry_pos++] = (c))
 
-static char *csv_errors[] = {"success",
+static const char *csv_errors[] = {"success",
                              "error parsing data while strict checking enabled",
                              "memory exhausted while increasing buffer size",
                              "data size too large",
@@ -81,7 +81,7 @@ csv_error(struct csv_parser *p)
   return p->status;
 }
 
-char *
+const char *
 csv_strerror(int status)
 {
   /* Return a textual description of status */
diff --git a/src/3rdparty/libcsv/libcsv.h b/src/3rdparty/libcsv/libcsv.h
index 3fbd3dd..b5a232e 100644
--- a/src/3rdparty/libcsv/libcsv.h
+++ b/src/3rdparty/libcsv/libcsv.h
@@ -62,7 +62,7 @@ int csv_init(struct csv_parser *p, unsigned char options);
 int csv_fini(struct csv_parser *p, void (*cb1)(void *, size_t, void *), void \
(*cb2)(int, void *), void *data);  void csv_free(struct csv_parser *p);
 int csv_error(struct csv_parser *p);
-char * csv_strerror(int error);
+const char * csv_strerror(int error);
 size_t csv_parse(struct csv_parser *p, const void *s, size_t len, void (*cb1)(void \
*, size_t, void *), void (*cb2)(int, void *), void *data);  size_t csv_write(void \
*dest, size_t dest_size, const void *src, size_t src_size);  int csv_fwrite(FILE *fp, \
const void *src, size_t src_size);


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic