Browse Source

ckdb - allow an empty merkle since it is possible for bitcoind to return one

master
kanoi 9 years ago
parent
commit
3e112c73e3
  1. 10
      src/ckdb.c
  2. 2
      src/ckdb.h

10
src/ckdb.c

@ -2783,14 +2783,13 @@ static enum cmd_values breakdown(K_ITEM **ml_item, char *buf, tv_t *now,
while (*end && *end != JSON_ARRAY_END)
end++;
if (end < next+1) {
LOGERR("JSON '%s' zero length value "
"was:%.32s... buf=%.32s...",
LOGWARNING("JSON '%s' zero length array"
" was:%.32s... buf=%.32s...",
transfer->name,
st = safe_text(was),
st2 = safe_text(buf));
FREENULL(st);
FREENULL(st2);
goto nogood;
}
siz = end - next;
end++;
@ -2812,14 +2811,13 @@ static enum cmd_values breakdown(K_ITEM **ml_item, char *buf, tv_t *now,
goto nogood;
}
if (next == end) {
LOGERR("JSON '%s' zero length value "
"was:%.32s... buf=%.32s...",
LOGWARNING("JSON '%s' zero length value"
" was:%.32s... buf=%.32s...",
transfer->name,
st = safe_text(was),
st2 = safe_text(buf));
FREENULL(st);
FREENULL(st2);
goto nogood;
}
siz = end - next;
}

2
src/ckdb.h

@ -55,7 +55,7 @@
#define DB_VLOCK "1"
#define DB_VERSION "1.0.4"
#define CKDB_VERSION DB_VERSION"-1.603"
#define CKDB_VERSION DB_VERSION"-1.610"
#define WHERE_FFL " - from %s %s() line %d"
#define WHERE_FFL_HERE __FILE__, __func__, __LINE__

Loading…
Cancel
Save