diff options
author | Jeremy Allison <jra@samba.org> | 2007-11-16 17:06:57 -0800 |
---|---|---|
committer | Jeremy Allison <jra@samba.org> | 2007-11-16 17:06:57 -0800 |
commit | b059e2cbf1d6190c996a1ff6b8f426a493ae937c (patch) | |
tree | 32a9bd49dc735bc45e3d4d2064829f92f65922ee /source3 | |
parent | 0cfad17e4ac727314487bed9a5f6166a6a1543eb (diff) | |
download | samba-b059e2cbf1d6190c996a1ff6b8f426a493ae937c.tar.gz samba-b059e2cbf1d6190c996a1ff6b8f426a493ae937c.tar.bz2 samba-b059e2cbf1d6190c996a1ff6b8f426a493ae937c.zip |
Ensure we use PATH_MAX for symlinks.
Jeremy.
(This used to be commit a90ef69350c5efcf8dcf95d4853cbe3c662d1ba3)
Diffstat (limited to 'source3')
-rw-r--r-- | source3/smbd/trans2.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/source3/smbd/trans2.c b/source3/smbd/trans2.c index 3abc0d065c..bb24db9ee1 100644 --- a/source3/smbd/trans2.c +++ b/source3/smbd/trans2.c @@ -4168,7 +4168,7 @@ total_data=%u (should be %u)\n", (unsigned int)total_data, (unsigned int)IVAL(pd case SMB_QUERY_FILE_UNIX_LINK: { - char *buffer = TALLOC_ARRAY(ctx, char, 1024); + char *buffer = TALLOC_ARRAY(ctx, char, PATH_MAX+1); if (!buffer) { reply_nterror(req, NT_STATUS_NO_MEMORY); @@ -4187,7 +4187,7 @@ total_data=%u (should be %u)\n", (unsigned int)total_data, (unsigned int)IVAL(pd return; #endif len = SMB_VFS_READLINK(conn,fullpathname, - buffer, 1023); + buffer, PATH_MAX); if (len == -1) { reply_unixerror(req, ERRDOS, ERRnoaccess); |