solved a duplicate memory allocation in the new API
Costa Tsaousis (ktsaou) committed
Nov 30, 2015 at 01:29 UTC
8d25e7ccd2970f5683a47c34a686edf31528455d
1 file changed
-3
src/rrd2json.c
-3
@@ -802,9 +802,6 @@ static RRDR *rrdr_create(RRDSET *st, int n)
802
r->t = malloc(n * sizeof(time_t));
803
if(unlikely(!r->t)) goto cleanup;
804
805
- r->t = malloc(n * sizeof(time_t));
806
- if(unlikely(!r->t)) goto cleanup;
807
-
805
r->v = malloc(n * r->d * sizeof(calculated_number));
806
if(unlikely(!r->v)) goto cleanup;
807