Commit f51cf14b authored by Bodo Möller's avatar Bodo Möller
Browse files

fix memory leak in err.c

parent 194dd046
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -3,6 +3,9 @@

 Changes between 0.9.6 and 0.9.7  [xx XXX 2000]

  *) Fix a memory leak in err.c: free err_data string if necessary.
     [Bodo Moeller]

  *) Function EC_POINTs_mul for simultaneous scalar multiplication
     of an arbitrary number of elliptic curve points, optionally
     including the generator defined for the EC_GROUP.
+9 −1
Original line number Diff line number Diff line
@@ -466,7 +466,15 @@ static unsigned long get_error_values(int inc, const char **file, int *line,
			}
		}

	if (data != NULL)
	if (data == NULL)
		{
		if (inc && (es->err_data[i] != NULL) && (es->err_data_flags[i] & ERR_TXT_MALLOCED))
			{
			OPENSSL_free(es->err_data[i]);
			es->err_data[i] = NULL;
			}
		}
	else
		{
		if (es->err_data[i] == NULL)
			{