mirror of
https://github.com/fluencelabs/redis
synced 2025-03-20 09:30:55 +00:00
Use inet_pton(3) in clusterCommand.
Replace inet_aton(3) call with the more future proof inet_pton(3) function which is capable of handling additional address families.
This commit is contained in:
parent
a6ea707cec
commit
693b640510
@ -2070,7 +2070,7 @@ void clusterCommand(redisClient *c) {
|
||||
long port;
|
||||
|
||||
/* Perform sanity checks on IP/port */
|
||||
if (inet_aton(c->argv[2]->ptr,&sa.sin_addr) == 0) {
|
||||
if (inet_pton(AF_INET,c->argv[0]->ptr,&(sa.sin_addr)) == 0) {
|
||||
addReplyError(c,"Invalid IP address in MEET");
|
||||
return;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user