summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPieter Noordhuis <pcnoordhuis@gmail.com>2010-11-22 10:37:14 +0100
committerPieter Noordhuis <pcnoordhuis@gmail.com>2010-11-22 10:37:14 +0100
commitb6b96f776ea2f954b50d553cd16f4990d70260dc (patch)
tree9e9812bced2fd8ba11cd11ec14af2e0d93485f34
parent537e64e94680b75826949af46e95f3507bdf66a8 (diff)
Make error messages consistent in casing
-rw-r--r--hiredis.c2
-rw-r--r--net.c2
-rw-r--r--test.c6
3 files changed, 5 insertions, 5 deletions
diff --git a/hiredis.c b/hiredis.c
index a2d8515..f6b1d54 100644
--- a/hiredis.c
+++ b/hiredis.c
@@ -347,7 +347,7 @@ static int processItem(redisReader *r) {
default:
byte = sdscatrepr(sdsempty(),p,1);
redisSetReplyReaderError(r,sdscatprintf(sdsempty(),
- "protocol error, got %s as reply type byte", byte));
+ "Protocol error, got %s as reply type byte", byte));
sdsfree(byte);
return -1;
}
diff --git a/net.c b/net.c
index 599ba9d..bdd191f 100644
--- a/net.c
+++ b/net.c
@@ -114,7 +114,7 @@ int redisContextConnectTcp(redisContext *c, const char *addr, int port) {
he = gethostbyname(addr);
if (he == NULL) {
__redisSetError(c,REDIS_ERR_OTHER,
- sdscatprintf(sdsempty(),"can't resolve: %s",addr));
+ sdscatprintf(sdsempty(),"Can't resolve: %s",addr));
close(s);
return REDIS_ERR;
}
diff --git a/test.c b/test.c
index dd9d92f..beccd60 100644
--- a/test.c
+++ b/test.c
@@ -99,7 +99,7 @@ static void test_blocking_connection() {
test("Returns error when host cannot be resolved: ");
c = redisConnect((char*)"idontexist.local", 6379);
test_cond(c->err == REDIS_ERR_OTHER &&
- strcmp(c->errstr,"can't resolve: idontexist.local") == 0);
+ strcmp(c->errstr,"Can't resolve: idontexist.local") == 0);
redisFree(c);
test("Returns error when the port is not open: ");
@@ -240,7 +240,7 @@ static void test_reply_reader() {
ret = redisReplyReaderGetReply(reader,NULL);
err = redisReplyReaderGetError(reader);
test_cond(ret == REDIS_ERR &&
- strcasecmp(err,"protocol error, got \"@\" as reply type byte") == 0);
+ strcasecmp(err,"Protocol error, got \"@\" as reply type byte") == 0);
redisReplyReaderFree(reader);
/* when the reply already contains multiple items, they must be free'd
@@ -253,7 +253,7 @@ static void test_reply_reader() {
ret = redisReplyReaderGetReply(reader,NULL);
err = redisReplyReaderGetError(reader);
test_cond(ret == REDIS_ERR &&
- strcasecmp(err,"protocol error, got \"@\" as reply type byte") == 0);
+ strcasecmp(err,"Protocol error, got \"@\" as reply type byte") == 0);
redisReplyReaderFree(reader);
test("Works with NULL functions for reply: ");