Upgrade to use sdb 1.4.0 (#14045)

This commit is contained in:
radare 2019-05-13 11:10:33 +02:00 committed by GitHub
parent 12c824cfd1
commit 4c87ee714e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 11 additions and 2 deletions

View File

@ -1 +1 @@
#define SDB_VERSION "1.3.0"
#define SDB_VERSION "1.4.0"

View File

@ -6,7 +6,7 @@ INCDIR=${PREFIX}/include
VAPIDIR=${DATADIR}/vala/vapi/
MANDIR=${DATADIR}/man/man1
SDBVER=1.3.0
SDBVER=1.4.0
BUILD_MEMCACHE=0

View File

@ -5,6 +5,7 @@
#include <stdarg.h>
#include <stdlib.h>
#include <fcntl.h>
#include <ctype.h>
#include "sdb.h"
typedef struct {
@ -757,6 +758,14 @@ next_quote:
*json++ = 0;
ok = sdb_json_set (s, cmd, json, val, 0);
} else {
while (*val && isspace (*val)) {
val++;
}
int i = strlen (cmd) - 1;
while (i >= 0 && isspace (cmd[i])) {
cmd[i] = '\0';
i--;
}
ok = sdb_set (s, cmd, val, 0);
}
if (encode) {