mirror of
https://github.com/pgbackrest/pgbackrest.git
synced 2024-12-14 10:13:05 +02:00
Rename lstRemove() to lstRemoveIdx().
This works better with the names of upcoming functions and seems sensible even in isolation.
This commit is contained in:
parent
dde0c2b0c9
commit
2eb1d1fee3
@ -171,7 +171,7 @@ lstInsert(List *this, unsigned int listIdx, const void *item)
|
||||
Remove an item from the list
|
||||
***********************************************************************************************************************************/
|
||||
List *
|
||||
lstRemove(List *this, unsigned int listIdx)
|
||||
lstRemoveIdx(List *this, unsigned int listIdx)
|
||||
{
|
||||
FUNCTION_TEST_BEGIN();
|
||||
FUNCTION_TEST_PARAM(LIST, this);
|
||||
|
@ -28,7 +28,7 @@ List *lstAdd(List *this, const void *item);
|
||||
List *lstClear(List *this);
|
||||
void *lstGet(const List *this, unsigned int listIdx);
|
||||
List *lstInsert(List *this, unsigned int listIdx, const void *item);
|
||||
List *lstRemove(List *this, unsigned int listIdx);
|
||||
List *lstRemoveIdx(List *this, unsigned int listIdx);
|
||||
MemContext *lstMemContext(const List *this);
|
||||
List *lstMove(List *this, MemContext *parentNew);
|
||||
unsigned int lstSize(const List *this);
|
||||
|
@ -371,7 +371,7 @@ infoBackupDataDelete(const InfoBackup *this, const String *backupDeleteLabel)
|
||||
InfoBackupData backupData = infoBackupData(this, idx);
|
||||
|
||||
if (strCmp(backupData.backupLabel, backupDeleteLabel) == 0)
|
||||
lstRemove(this->backup, idx);
|
||||
lstRemoveIdx(this->backup, idx);
|
||||
}
|
||||
|
||||
FUNCTION_LOG_RETURN_VOID();
|
||||
|
@ -253,7 +253,7 @@ protocolParallelResult(ProtocolParallel *this)
|
||||
if (protocolParallelJobState(job) == protocolParallelJobStateDone)
|
||||
{
|
||||
result = protocolParallelJobMove(job, memContextCurrent());
|
||||
lstRemove(this->jobList, jobIdx);
|
||||
lstRemoveIdx(this->jobList, jobIdx);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
@ -83,7 +83,7 @@ testRun(void)
|
||||
}
|
||||
|
||||
// Remove first item
|
||||
TEST_RESULT_VOID(lstRemove(list, 0), "remove first item");
|
||||
TEST_RESULT_VOID(lstRemoveIdx(list, 0), "remove first item");
|
||||
|
||||
// Read them back and check values
|
||||
for (unsigned int listIdx = 0; listIdx < lstSize(list); listIdx++)
|
||||
@ -93,7 +93,7 @@ testRun(void)
|
||||
}
|
||||
|
||||
// Remove last item
|
||||
TEST_RESULT_VOID(lstRemove(list, lstSize(list) - 1), "remove last item");
|
||||
TEST_RESULT_VOID(lstRemoveIdx(list, lstSize(list) - 1), "remove last item");
|
||||
|
||||
// Read them back and check values
|
||||
for (unsigned int listIdx = 0; listIdx < lstSize(list); listIdx++)
|
||||
|
Loading…
Reference in New Issue
Block a user