summaryrefslogtreecommitdiff
path: root/sal/osl/unx
diff options
context:
space:
mode:
authorPedro Giffuni <pfg@apache.org>2015-12-02 14:47:01 +0000
committerPedro Giffuni <pfg@apache.org>2015-12-02 14:47:01 +0000
commit7f413ffa8cebd56cb5fb4cdd8138045c26f842de (patch)
tree389d8201008e2f02075810099aaa4c2cc8f5c3c4 /sal/osl/unx
parent9471f6b668106e031b74a25460c1cf73a04cd119 (diff)
Off by one using readlink(2)
CID 705623, 982797
Notes
Notes: prefer: 95f8cb6823f21dd97b380136286e87e0ffa2fb24
Diffstat (limited to 'sal/osl/unx')
-rw-r--r--sal/osl/unx/file_misc.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/sal/osl/unx/file_misc.cxx b/sal/osl/unx/file_misc.cxx
index 189d7fb817d8..09d1a94e781f 100644
--- a/sal/osl/unx/file_misc.cxx
+++ b/sal/osl/unx/file_misc.cxx
@@ -969,7 +969,7 @@ static int oslDoCopyLink(const sal_Char* pszSourceFileName, const sal_Char* pszD
pszLinkContent[0] = '\0';
- nRet = readlink(pszSourceFileName,pszLinkContent,PATH_MAX);
+ nRet = readlink(pszSourceFileName,pszLinkContent,PATH_MAX-1);
if ( nRet < 0 )
{