mirror of
https://github.com/pgbackrest/pgbackrest.git
synced 2024-12-12 10:04:14 +02:00
Fix leak in archivePushDropWarning().
This commit is contained in:
parent
bf9e331ac1
commit
675b4ae251
@ -41,15 +41,19 @@ Ready file extension constants
|
||||
Format the warning when a file is dropped
|
||||
***********************************************************************************************************************************/
|
||||
static String *
|
||||
archivePushDropWarning(const String *walFile, uint64_t queueMax)
|
||||
archivePushDropWarning(const String *const walFile, const uint64_t queueMax)
|
||||
{
|
||||
FUNCTION_TEST_BEGIN();
|
||||
FUNCTION_TEST_PARAM(STRING, walFile);
|
||||
FUNCTION_TEST_PARAM(UINT64, queueMax);
|
||||
FUNCTION_TEST_END();
|
||||
|
||||
FUNCTION_TEST_RETURN(
|
||||
STRING, strNewFmt("dropped WAL file '%s' because archive queue exceeded %s", strZ(walFile), strZ(strSizeFormat(queueMax))));
|
||||
String *const size = strSizeFormat(queueMax);
|
||||
String *const result = strNewFmt("dropped WAL file '%s' because archive queue exceeded %s", strZ(walFile), strZ(size));
|
||||
|
||||
strFree(size);
|
||||
|
||||
FUNCTION_TEST_RETURN(STRING, result);
|
||||
}
|
||||
|
||||
/***********************************************************************************************************************************
|
||||
|
Loading…
Reference in New Issue
Block a user