diff options
author | Chuck Lever <chuck.lever@oracle.com> | 2008-06-23 12:36:53 -0400 |
---|---|---|
committer | Trond Myklebust <Trond.Myklebust@netapp.com> | 2008-07-09 12:09:28 -0400 |
commit | ce3b7e1906ebbe96753fe090b36de6ffb8e0e0e7 (patch) | |
tree | 7518683c3a5818a0d48d377fa5dd4a37faddaec7 /include/linux/inet.h | |
parent | d1aa08257312f1439c1ab7c8a18e3856f9530f46 (diff) |
NFS: Add string length argument to nfs_parse_server_address
To make nfs_parse_server_address() more generally useful, allow it to
accept input strings that are not terminated with '\0'.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Diffstat (limited to 'include/linux/inet.h')
-rw-r--r-- | include/linux/inet.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/include/linux/inet.h b/include/linux/inet.h index 1354080cf8cf..4cca05c9678e 100644 --- a/include/linux/inet.h +++ b/include/linux/inet.h | |||
@@ -44,6 +44,13 @@ | |||
44 | 44 | ||
45 | #include <linux/types.h> | 45 | #include <linux/types.h> |
46 | 46 | ||
47 | /* | ||
48 | * These mimic similar macros defined in user-space for inet_ntop(3). | ||
49 | * See /usr/include/netinet/in.h . | ||
50 | */ | ||
51 | #define INET_ADDRSTRLEN (16) | ||
52 | #define INET6_ADDRSTRLEN (48) | ||
53 | |||
47 | extern __be32 in_aton(const char *str); | 54 | extern __be32 in_aton(const char *str); |
48 | extern int in4_pton(const char *src, int srclen, u8 *dst, int delim, const char **end); | 55 | extern int in4_pton(const char *src, int srclen, u8 *dst, int delim, const char **end); |
49 | extern int in6_pton(const char *src, int srclen, u8 *dst, int delim, const char **end); | 56 | extern int in6_pton(const char *src, int srclen, u8 *dst, int delim, const char **end); |