diff options
author | Sam Roberts <vieuxtech@gmail.com> | 2012-05-08 10:55:33 -0700 |
---|---|---|
committer | Sam Roberts <vieuxtech@gmail.com> | 2012-05-08 10:55:33 -0700 |
commit | ac59bcbeac7b8b7be367e3a475010a36ab03057e (patch) | |
tree | 6c844f031ad6841da2b7325cfdbd537184a04ea9 | |
parent | 04be61f88df2277fd0d2010b2deb851d9b081923 (diff) | |
download | luasocket-ac59bcbeac7b8b7be367e3a475010a36ab03057e.tar.gz luasocket-ac59bcbeac7b8b7be367e3a475010a36ab03057e.tar.bz2 luasocket-ac59bcbeac7b8b7be367e3a475010a36ab03057e.zip |
Reword error msg to distinguish between service and server
servname is easily confused with "server name", making it seem
as if the server name couldn't be resolved.
-rw-r--r-- | src/usocket.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/usocket.c b/src/usocket.c index 80d4d70..a168bf6 100644 --- a/src/usocket.c +++ b/src/usocket.c | |||
@@ -439,12 +439,12 @@ const char *socket_gaistrerror(int err) { | |||
439 | case EAI_FAMILY: return "ai_family not supported"; | 439 | case EAI_FAMILY: return "ai_family not supported"; |
440 | case EAI_MEMORY: return "memory allocation failure"; | 440 | case EAI_MEMORY: return "memory allocation failure"; |
441 | case EAI_NONAME: | 441 | case EAI_NONAME: |
442 | return "hostname or servname not provided, or not known"; | 442 | return "host or service not provided, or not known"; |
443 | case EAI_OVERFLOW: return "argument buffer overflow"; | 443 | case EAI_OVERFLOW: return "argument buffer overflow"; |
444 | #ifdef EAI_PROTOCOL | 444 | #ifdef EAI_PROTOCOL |
445 | case EAI_PROTOCOL: return "resolved protocol is unknown"; | 445 | case EAI_PROTOCOL: return "resolved protocol is unknown"; |
446 | #endif | 446 | #endif |
447 | case EAI_SERVICE: return "servname not supported for socktype"; | 447 | case EAI_SERVICE: return "service not supported for socket type"; |
448 | case EAI_SOCKTYPE: return "ai_socktype not supported"; | 448 | case EAI_SOCKTYPE: return "ai_socktype not supported"; |
449 | case EAI_SYSTEM: return strerror(errno); | 449 | case EAI_SYSTEM: return strerror(errno); |
450 | default: return "unknown error"; | 450 | default: return "unknown error"; |