/**
* nfs_string_to_sockaddr - convert string address to sockaddr
* @address: pointer to presentation format address to convert
- * @addrlen: length of presentation address
* @sap: pointer to socket address buffer to fill in
* @salen: IN: length of address buffer
* OUT: length of converted socket address
* See RFC 4038 section 5.1 or RFC 3513 section 2.2 for more details
* on presenting IPv6 addresses as text strings.
*/
-int nfs_string_to_sockaddr(const char *address, const size_t addrlen,
- struct sockaddr *sap, socklen_t *salen)
+int nfs_string_to_sockaddr(const char *address, struct sockaddr *sap,
+ socklen_t *salen)
{
struct addrinfo *gai_results;
struct addrinfo gai_hint = {
const socklen_t, struct pmap *);
int nfs_gethostbyname(const char *, struct sockaddr_in *);
int nfs_name_to_address(const char *, struct sockaddr *, socklen_t *);
-int nfs_string_to_sockaddr(const char *, const size_t,
- struct sockaddr *, socklen_t *);
+int nfs_string_to_sockaddr(const char *, struct sockaddr *, socklen_t *);
int nfs_present_sockaddr(const struct sockaddr *,
const socklen_t, char *, const size_t);
int nfs_callback_address(const struct sockaddr *, const socklen_t,
option = po_get(options, "addr");
if (option == NULL)
return 0;
- if (!nfs_string_to_sockaddr(option, strlen(option),
- nfs_saddr, nfs_salen))
+ if (!nfs_string_to_sockaddr(option, nfs_saddr, nfs_salen))
return 0;
option = po_get(options, "mountaddr");
if (option == NULL) {
memcpy(mnt_saddr, nfs_saddr, *nfs_salen);
*mnt_salen = *nfs_salen;
- } else if (!nfs_string_to_sockaddr(option, strlen(option),
- mnt_saddr, mnt_salen))
+ } else if (!nfs_string_to_sockaddr(option, mnt_saddr, mnt_salen))
return 0;
return 1;