mirror of
https://github.com/fluencelabs/redis
synced 2025-06-23 14:01:34 +00:00
sdsformatip() removed.
Specialized single-use function. Not the best match for sds.c btw. Also genClientPeerId() is no longer static: we need symbols.
This commit is contained in:
@ -962,15 +962,6 @@ sds sdsjoin(char **argv, int argc, char *sep) {
|
||||
return join;
|
||||
}
|
||||
|
||||
sds sdsformatip(char *ip, int port) {
|
||||
if (port >= 0)
|
||||
return sdscatfmt(sdsempty(),
|
||||
strchr(ip,':') ? "[%s]:%i" : "%s:%i", ip, port);
|
||||
else
|
||||
return sdscatfmt(sdsempty(),
|
||||
strchr(ip,':') ? "[%s]" : "%s", ip);
|
||||
}
|
||||
|
||||
#ifdef SDS_TEST_MAIN
|
||||
#include <stdio.h>
|
||||
#include "testhelp.h"
|
||||
|
Reference in New Issue
Block a user