diff options
author | Volker Lendecke <vl@samba.org> | 2009-01-30 15:04:44 +0100 |
---|---|---|
committer | Volker Lendecke <vl@samba.org> | 2009-06-02 11:58:22 +0200 |
commit | 83ffbb4ec4e0519cd4f9c5f95e11d70c18a1b25b (patch) | |
tree | f921c19ac0326ea2baf71825b8daf5d10bec0c16 | |
parent | cdb765a76caaa582b6406bd34279d04e4be9d6f2 (diff) | |
download | samba-83ffbb4ec4e0519cd4f9c5f95e11d70c18a1b25b.tar.gz samba-83ffbb4ec4e0519cd4f9c5f95e11d70c18a1b25b.tar.bz2 samba-83ffbb4ec4e0519cd4f9c5f95e11d70c18a1b25b.zip |
Remove a variable used just once
-rw-r--r-- | source3/smbd/vfs.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/source3/smbd/vfs.c b/source3/smbd/vfs.c index 0f70669772..bc6fd18b8e 100644 --- a/source3/smbd/vfs.c +++ b/source3/smbd/vfs.c @@ -871,7 +871,6 @@ NTSTATUS check_reduced_name(connection_struct *conn, const char *fname) bool free_resolved_name = False; #endif char *resolved_name = NULL; - size_t con_path_len = strlen(conn->connectpath); char *p = NULL; DEBUG(3,("reduce_name [%s] [%s]\n", fname, conn->connectpath)); @@ -957,7 +956,9 @@ NTSTATUS check_reduced_name(connection_struct *conn, const char *fname) } /* Check for widelinks allowed. */ - if (!lp_widelinks(SNUM(conn)) && (strncmp(conn->connectpath, resolved_name, con_path_len) != 0)) { + if (!lp_widelinks(SNUM(conn)) + && (strncmp(conn->connectpath, resolved_name, + strlen(conn->connectpath)) != 0)) { DEBUG(2, ("reduce_name: Bad access attempt: %s is a symlink outside the share path", fname)); if (free_resolved_name) { SAFE_FREE(resolved_name); |