* POSSIBILITY OF SUCH DAMAGE.
*/
-#define REDIS_VERSION "1.1.90"
+#define REDIS_VERSION "1.1.91"
#include "fmacros.h"
#include "config.h"
lenobj = createObject(REDIS_STRING,
sdscatprintf(sdsempty(),"%lu\r\n",
- stringObjectLen(argv[j])));
+ (unsigned long) stringObjectLen(argv[j])));
lenobj->refcount = 0;
outv[outc++] = lenobj;
}
snprintf(buf,sizeof(buf),"%.17g",d);
addReplySds(c,sdscatprintf(sdsempty(),"$%lu\r\n%s\r\n",
- strlen(buf),buf));
+ (unsigned long) strlen(buf),buf));
}
static void addReplyBulkLen(redisClient *c, robj *obj) {
len++;
}
}
- addReplySds(c,sdscatprintf(sdsempty(),"$%lu\r\n",len));
+ addReplySds(c,sdscatprintf(sdsempty(),"$%lu\r\n",(unsigned long)len));
}
static void acceptHandler(aeEventLoop *el, int fd, void *privdata, int mask) {
case 253: *val = R_Nan; return 0;
default:
if (fread(buf,len,1,fp) == 0) return -1;
+ buf[len] = '\0';
sscanf(buf, "%lg", val);
return 0;
}
static void infoCommand(redisClient *c) {
sds info = genRedisInfoString();
- addReplySds(c,sdscatprintf(sdsempty(),"$%lu\r\n",sdslen(info)));
+ addReplySds(c,sdscatprintf(sdsempty(),"$%lu\r\n",
+ (unsigned long)sdslen(info)));
addReplySds(c,info);
addReply(c,shared.crlf);
}
snprintf(seldb,sizeof(seldb),"%d",dictid);
buf = sdscatprintf(buf,"*2\r\n$6\r\nSELECT\r\n$%lu\r\n%s\r\n",
- strlen(seldb),seldb);
+ (unsigned long)strlen(seldb),seldb);
server.appendseldb = dictid;
}
robj *o = argv[j];
o = getDecodedObject(o);
- buf = sdscatprintf(buf,"$%lu\r\n",sdslen(o->ptr));
+ buf = sdscatprintf(buf,"$%lu\r\n",(unsigned long)sdslen(o->ptr));
buf = sdscatlen(buf,o->ptr,sdslen(o->ptr));
buf = sdscatlen(buf,"\r\n",2);
decrRefCount(o);