Null-terminate the string in percent_decode() so that we don't depend on
malloc() returning zeroed storage or dump core while starting up. Found-by: /etc/malloc.conf ->AJ
This commit is contained in:
parent
43e3da75f2
commit
baba602eab
@ -26,7 +26,7 @@
|
||||
* OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* $Id$
|
||||
* $Id: util.c,v 1.1 1997/01/30 21:43:44 wollman Exp $
|
||||
*/
|
||||
|
||||
#include <sys/types.h>
|
||||
@ -148,6 +148,7 @@ percent_decode(const char *uri)
|
||||
*s++ = *uri++;
|
||||
}
|
||||
}
|
||||
*s = '\0';
|
||||
return rv;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user