]> git.decadent.org.uk Git - nfs-utils.git/blobdiff - utils/mountd/cache.c
Don't complain if two exports of different types match the same IP address.
[nfs-utils.git] / utils / mountd / cache.c
index 6cf24ceb4f9f9d3b919cbe1c24cbc22e290945a5..ed7fe3534ad3e5ae4ffff535b434913f221812b8 100644 (file)
@@ -490,6 +490,7 @@ void nfsd_export(FILE *f)
        int i;
        char *dom, *path;
        nfs_export *exp, *found = NULL;
+       int found_type = 0;
 
 
        if (readline(fileno(f), &lbuf, &lbuflen) != 1)
@@ -516,9 +517,10 @@ void nfsd_export(FILE *f)
                                continue;
                        if (strcmp(path, exp->m_export.e_path))
                                continue;
-                       if (!found)
+                       if (!found) {
                                found = exp;
-                       else {
+                               found_type = i;
+                       } else if (found_type == i) {
                                xlog(L_WARNING, "%s exported to both %s and %s in %s",
                                     path, exp->m_client->m_hostname, found->m_client->m_hostname,
                                     dom);