summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 28c8c6a)
raw | patch | inline | side by side (parent: 28c8c6a)
author | Sebastian Harl <sh@tokkee.org> | |
Fri, 25 Sep 2009 20:23:15 +0000 (22:23 +0200) | ||
committer | Sebastian Harl <sh@tokkee.org> | |
Fri, 25 Sep 2009 20:23:15 +0000 (22:23 +0200) |
debian/changelog | patch | blob | history | |
debian/patches/compiler-warning-fixes | [new file with mode: 0644] | patch | blob |
debian/patches/series | patch | blob | history |
diff --git a/debian/changelog b/debian/changelog
index 7f62b3fb3fcdfdaa10370f833e3e6325092edc34..2337d5a4425d0e08da8098282695f4aa209b4282 100644 (file)
--- a/debian/changelog
+++ b/debian/changelog
* debian/patches:
- Removed bts494874-gnu-kfreebsd - included upstream.
- Removed bts332766-negative-timestamps - included upstream.
- - Removed compiler-warning-fixes - included upstream.
+ - Updated compiler-warning-fixes for RRDtool 1.4.
- Updated bts428778-floating-point-exception for RRDtool 1.4.
* Added debian/README.source:
- The file includes a pointer to /usr/share/doc/quilt/README.source.
* debian/librrd4.symbols:
- Added symbols introduced in 1.4~rc2.
- -- Sebastian Harl <tokkee@debian.org> Fri, 25 Sep 2009 18:54:11 +0200
+ -- Sebastian Harl <tokkee@debian.org> Fri, 25 Sep 2009 22:22:05 +0200
rrdtool (1.3.8-1) unstable; urgency=low
diff --git a/debian/patches/compiler-warning-fixes b/debian/patches/compiler-warning-fixes
--- /dev/null
@@ -0,0 +1,147 @@
+diff a/src/rrd_fetch_libdbi.c b/src/rrd_fetch_libdbi.c
+--- a/src/rrd_fetch_libdbi.c
++++ b/src/rrd_fetch_libdbi.c
+@@ -17,20 +17,20 @@ struct sql_table_helper {
+ };
+
+ /* the prototypes */
+-void _sql_close(struct sql_table_helper* th);
+-int _sql_setparam(struct sql_table_helper* th,char* key, char* value);
+-int _sql_fetchrow(struct sql_table_helper* th,time_t *timestamp, rrd_value_t *value,int ordered);
+-char* _find_next_separator(char* start,char separator);
+-char* _find_next_separator_twice(char*start,char separator);
+-char _hexcharhelper(char c);
+-int _inline_unescape (char* string);
+-double rrd_fetch_dbi_double(dbi_result *result,int idx);
+-long rrd_fetch_dbi_long(dbi_result *result,int idx);
++static void _sql_close(struct sql_table_helper* th);
++static int _sql_setparam(struct sql_table_helper* th,char* key, char* value);
++static int _sql_fetchrow(struct sql_table_helper* th,time_t *timestamp, rrd_value_t *value,int ordered);
++static char* _find_next_separator(char* start,char separator);
++static char* _find_next_separator_twice(char*start,char separator);
++static char _hexcharhelper(char c);
++static int _inline_unescape (char* string);
++static double rrd_fetch_dbi_double(dbi_result *result,int idx);
++static long rrd_fetch_dbi_long(dbi_result *result,int idx);
+
+ /* the real code */
+
+ /* helpers to get correctly converted values from DB*/
+-long rrd_fetch_dbi_long(dbi_result *result,int idx) {
++static long rrd_fetch_dbi_long(dbi_result *result,int idx) {
+ char *ptmp="";
+ long value=DNAN;
+ /* get the attributes for this filed */
+@@ -87,7 +87,7 @@ long rrd_fetch_dbi_long(dbi_result *result,int idx) {
+ return value;
+ }
+
+-double rrd_fetch_dbi_double(dbi_result *result,int idx) {
++static double rrd_fetch_dbi_double(dbi_result *result,int idx) {
+ char *ptmp="";
+ double value=DNAN;
+ /* get the attributes for this filed */
+@@ -144,7 +144,7 @@ double rrd_fetch_dbi_double(dbi_result *result,int idx) {
+ return value;
+ }
+
+-void _sql_close(struct sql_table_helper* th) {
++static void _sql_close(struct sql_table_helper* th) {
+ /* close only if connected */
+ if (th->conn) {
+ if (getenv("RRDDEBUGSQL")) { fprintf(stderr,"RRDDEBUGSQL: %li: close connection\n",time(NULL) ); }
+@@ -158,7 +158,7 @@ void _sql_close(struct sql_table_helper* th) {
+ }
+ }
+
+-int _sql_setparam(struct sql_table_helper* th,char* key, char* value) {
++static int _sql_setparam(struct sql_table_helper* th,char* key, char* value) {
+ char* dbi_errstr=NULL;
+ dbi_driver driver;
+ /* if not connected */
+@@ -200,7 +200,7 @@ int _sql_setparam(struct sql_table_helper* th,char* key, char* value) {
+ return 0;
+ }
+
+-int _sql_fetchrow(struct sql_table_helper* th,time_t *timestamp, rrd_value_t *value,int ordered) {
++static int _sql_fetchrow(struct sql_table_helper* th,time_t *timestamp, rrd_value_t *value,int ordered) {
+ char* dbi_errstr=NULL;
+ char sql[10240];
+ time_t startt=0,endt=0;
+@@ -269,7 +269,7 @@ int _sql_fetchrow(struct sql_table_helper* th,time_t *timestamp, rrd_value_t *va
+ return 1;
+ }
+
+-char* _find_next_separator(char* start,char separator) {
++static char* _find_next_separator(char* start,char separator) {
+ char* found=strchr(start,separator);
+ /* have we found it */
+ if (found) {
+@@ -282,7 +282,7 @@ char* _find_next_separator(char* start,char separator) {
+ return NULL;
+ }
+
+-char* _find_next_separator_twice(char*start,char separator) {
++static char* _find_next_separator_twice(char*start,char separator) {
+ char *found=start;
+ /* find next separator in string*/
+ while (found) {
+@@ -300,7 +300,7 @@ char* _find_next_separator_twice(char*start,char separator) {
+ return NULL;
+ }
+
+-char _hexcharhelper(char c) {
++static char _hexcharhelper(char c) {
+ switch (c) {
+ case '0': return 0 ; break;
+ case '1': return 1 ; break;
+@@ -328,7 +328,7 @@ char _hexcharhelper(char c) {
+ return -1;
+ }
+
+-int _inline_unescape (char* string) {
++static int _inline_unescape (char* string) {
+ char *src=string;
+ char *dst=string;
+ char c,h1,h2;
+@@ -341,9 +341,15 @@ int _inline_unescape (char* string) {
+ } else {
+ /* try to calculate hex value from the next 2 values*/
+ h1=_hexcharhelper(*src);
+- if (h1<0) { rrd_set_error( "string escape error at: %s\n",string);return(1); }
++ if (h1 == (char)-1) {
++ rrd_set_error("string escape error at: %s\n",string);
++ return(1);
++ }
+ h2=_hexcharhelper(*(src+1));
+- if (h2<0) { rrd_set_error( "string escape error at: %s\n",string);return(1); }
++ if (h1 == (char)-1) {
++ rrd_set_error("string escape error at: %s\n",string);
++ return(1);
++ }
+ c=h2+(h1<<4);
+ /* increase src pointer by 2 skiping 2 chars */
+ src+=2;
+@@ -358,8 +364,8 @@ int _inline_unescape (char* string) {
+
+ int
+ rrd_fetch_fn_libdbi(
+- char *filename, /* name of the rrd */
+- enum cf_en cf_idx, /* which consolidation function ?*/
++ const char *filename, /* name of the rrd */
++ enum cf_en cf_idx __attribute__((unused)), /* consolidation function */
+ time_t *start,
+ time_t *end, /* which time frame do you want ?
+ * will be changed to represent reality */
+diff a/src/rrd_tool.h b/src/rrd_tool.h
+--- a/src/rrd_tool.h
++++ b/src/rrd_tool.h
+@@ -94,7 +94,7 @@ extern "C" {
+
+
+ #ifdef HAVE_LIBDBI
+-int rrd_fetch_fn_libdbi(char *filename, enum cf_en cf_idx,
++int rrd_fetch_fn_libdbi(const char *filename, enum cf_en cf_idx,
+ time_t *start,time_t *end,
+ unsigned long *step,
+ unsigned long *ds_cnt,
diff --git a/debian/patches/series b/debian/patches/series
index e472686769fb37a4d5bcdabd40668061ac5a8c58..ca05d95d1071efc55f1122291bb7251969c1de94 100644 (file)
--- a/debian/patches/series
+++ b/debian/patches/series
no-rpath-for-perl
implicit-decl-fix
bts530814-hurd
+compiler-warning-fixes