Bugzilla bug 135008: fixed the bug that PL_Base64Decode may step before

the buffer if the source string length is 0.  Thanks to Roger Chickering
<rogc@netscape.com> for the bug fix.


git-svn-id: svn://10.0.0.236/trunk@118019 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
wtc%netscape.com
2002-04-03 19:09:25 +00:00
parent 29ef230c2e
commit 2fdf7b63d1

View File

@@ -383,7 +383,7 @@ PL_Base64Decode
srclen = PL_strlen(src);
}
if( 0 == (srclen & 3) )
if( srclen && (0 == (srclen & 3)) )
{
if( (char)'=' == src[ srclen-1 ] )
{