From: Florian Forster Date: Thu, 9 Sep 2010 12:29:24 +0000 (+0200) Subject: src/common.c: Fix "ds_list_from_rrd_file". X-Git-Tag: v4.0.0~29 X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=74280b2a518e2b4a2bce6d7bec5c829cab9a9ca7;hp=c4c851ce35ad88eff7f843dbced132f55b8a2f6c;p=collection4.git src/common.c: Fix "ds_list_from_rrd_file". --- diff --git a/src/common.c b/src/common.c index 2a5bf45..9a2196b 100644 --- a/src/common.c +++ b/src/common.c @@ -101,13 +101,13 @@ int ds_list_from_rrd_file (char *file, /* {{{ */ continue; keylen = strlen (ptr->key); - if (keylen < strlen ("ds[?].index")) + if (keylen < strlen ("ds[?].type")) continue; - dslen = keylen - strlen ("ds[].index"); + dslen = keylen - strlen ("ds[].type"); assert (dslen >= 1); - if (strcmp ("].index", ptr->key + (strlen ("ds[") + dslen)) != 0) + if (strcmp ("].type", ptr->key + (strlen ("ds[") + dslen)) != 0) continue; ds = malloc (dslen + 1);