]> git.ipfire.org Git - thirdparty/rrdtool-1.x.git/commitdiff
fix #760
authorTobias Oetiker <tobi@oetiker.ch>
Tue, 3 Jan 2017 15:18:24 +0000 (16:18 +0100)
committerTobias Oetiker <tobi@oetiker.ch>
Tue, 3 Jan 2017 15:18:24 +0000 (16:18 +0100)
src/rrd_graph.c

index 2ec9462f68587fa6b8082fbd30146d6dd686bc9e..02f03ca590555262ebcea1cc05893e5b282d44a5 100644 (file)
@@ -2279,7 +2279,7 @@ int leg_place(
 /* the xaxis labels are determined from the number of seconds per pixel
    in the requested graph */
 
-int calc_horizontal_grid(
+int calc_horizontal_grid (
     image_desc_t
     *im)
 {
@@ -2336,7 +2336,7 @@ int calc_horizontal_grid(
                       (im->ygrid_scale.gridstep *
                        (double) im->ygrid_scale.labfact * im->viewfactor /
                        im->magfact));
-            if (fractionals < 0) {  /* small amplitude. */
+            if (fractionals = 0) {  /* small amplitude. */
                 int       len = decimals - fractionals + 1;
 
                 if (im->unitslength < len + 2)