# HG changeset patch # User Markus Mützel # Date 1683871241 -7200 # Node ID e2911d0176dc7cb68fa9c8c6e528717ff8937f1d # Parent 66ecc0d4d6ce9e0e363d54ff99edfe4c3315b6b7 uniconv-wrappers: Avoid freeing uninitialized pointer (bug #64182). * liboctave/wrappers/uniconv-wrappers.c (octave_u8_conv_to_encoding_intern): Initialize pointer with NULL that might be freed without assignment otherwise. diff -r 66ecc0d4d6ce -r e2911d0176dc liboctave/wrappers/uniconv-wrappers.c --- a/liboctave/wrappers/uniconv-wrappers.c Sun May 07 18:13:19 2023 +0200 +++ b/liboctave/wrappers/uniconv-wrappers.c Fri May 12 08:00:41 2023 +0200 @@ -67,7 +67,7 @@ || (tocode[2] != 'f' && tocode[2] != 'F')) padlen++; - uint8_t *u8_str; + uint8_t *u8_str = NULL; const uint8_t *cu8_str; if (srclen < padlen) {