/* Note: caller frees hostname and export path, even on error.  */
static int nfs_parse_devname(const char *dev_name, char **hostname, size_t maxnamlen, char **export_path, size_t maxpathlen)
/* Note: caller frees hostname and export path, even on error.  */
static int nfs_parse_devname(const char *dev_name, char **hostname, size_t maxnamlen, char **export_path, size_t maxpathlen)
{
	if (*dev_name == '[')
		return nfs_parse_protected_hostname(dev_name,
						    hostname, maxnamlen,
						    export_path, maxpathlen);
	return nfs_parse_simple_hostname(dev_name,
					 hostname, maxnamlen,
					 export_path, maxpathlen);
}