r4423: give lp_parm_int() and lp_parm_ulong() default values
[samba.git] / source4 / ntvfs / posix / vfs_posix.c
index 6f4de1e0388b4439ec199bb5ef0213d8531cf86c..eecc379064a42621455fb6bf829bed4cc303d170 100644 (file)
@@ -34,7 +34,6 @@
 static void pvfs_setup_options(struct pvfs_state *pvfs)
 {
        int snum = pvfs->tcon->service;
-       int delay;
        const char *eadb;
 
        if (lp_map_hidden(snum))     pvfs->flags |= PVFS_FLAG_MAP_HIDDEN;
@@ -53,11 +52,7 @@ static void pvfs_setup_options(struct pvfs_state *pvfs)
        if (lp_parm_bool(snum, "posix", "xattr", True)) pvfs->flags |= PVFS_FLAG_XATTR_ENABLE;
 #endif
 
-       pvfs->sharing_violation_delay = 1000000;
-       delay = lp_parm_int(snum, "posix", "sharedelay");
-       if (delay != -1) {
-               pvfs->sharing_violation_delay = delay;
-       }
+       pvfs->sharing_violation_delay = lp_parm_int(snum, "posix", "sharedelay", 1000000);
 
        pvfs->share_name = talloc_strdup(pvfs, lp_servicename(snum));
 
@@ -81,7 +76,6 @@ static void pvfs_setup_options(struct pvfs_state *pvfs)
                }
        }
 
-
        if (pvfs->flags & PVFS_FLAG_XATTR_ENABLE) {
                pvfs->fs_attribs |= FS_ATTR_NAMED_STREAMS;
        }