mirror of
https://github.com/pgbackrest/pgbackrest.git
synced 2025-01-18 04:58:51 +02:00
Use PROJECT_NAME constant instead of string literal.
This commit is contained in:
parent
39bb8a0d3a
commit
3b9c31f6e3
@ -99,7 +99,7 @@ storageSftpLibSsh2SessionFreeResource(THIS_VOID)
|
||||
{
|
||||
do
|
||||
{
|
||||
rc = libssh2_session_disconnect_ex(this->session, SSH_DISCONNECT_BY_APPLICATION, "pgbackrest instance shutdown", "");
|
||||
rc = libssh2_session_disconnect_ex(this->session, SSH_DISCONNECT_BY_APPLICATION, PROJECT_NAME " instance shutdown", "");
|
||||
}
|
||||
while (storageSftpWaitFd(this, rc));
|
||||
|
||||
|
@ -73,7 +73,7 @@ Macros for defining groups of functions that implement commands
|
||||
// Set of functions mimicking libssh2 shutdown and disconnect
|
||||
#define HRNLIBSSH2_MACRO_SHUTDOWN() \
|
||||
{.function = HRNLIBSSH2_SFTP_SHUTDOWN, .resultInt = 0}, \
|
||||
{.function = HRNLIBSSH2_SESSION_DISCONNECT_EX, .param ="[11,\"pgbackrest instance shutdown\",\"\"]", .resultInt = 0}, \
|
||||
{.function = HRNLIBSSH2_SESSION_DISCONNECT_EX, .param ="[11,\"pgBackRest instance shutdown\",\"\"]", .resultInt = 0}, \
|
||||
{.function = HRNLIBSSH2_SESSION_FREE, .resultInt = 0}, \
|
||||
{.function = NULL} \
|
||||
|
||||
|
@ -4755,10 +4755,10 @@ testRun(void)
|
||||
{.function = HRNLIBSSH2_SESSION_BLOCK_DIRECTIONS, .resultInt = SSH2_NO_BLOCK_READING_WRITING},
|
||||
|
||||
{.function = HRNLIBSSH2_SFTP_SHUTDOWN, .resultInt = LIBSSH2_ERROR_NONE},
|
||||
{.function = HRNLIBSSH2_SESSION_DISCONNECT_EX, .param = "[11,\"pgbackrest instance shutdown\",\"\"]",
|
||||
{.function = HRNLIBSSH2_SESSION_DISCONNECT_EX, .param = "[11,\"pgBackRest instance shutdown\",\"\"]",
|
||||
.resultInt = LIBSSH2_ERROR_EAGAIN},
|
||||
{.function = HRNLIBSSH2_SESSION_BLOCK_DIRECTIONS, .resultInt = SSH2_NO_BLOCK_READING_WRITING},
|
||||
{.function = HRNLIBSSH2_SESSION_DISCONNECT_EX, .param = "[11,\"pgbackrest instance shutdown\",\"\"]",
|
||||
{.function = HRNLIBSSH2_SESSION_DISCONNECT_EX, .param = "[11,\"pgBackRest instance shutdown\",\"\"]",
|
||||
.resultInt = LIBSSH2_ERROR_NONE},
|
||||
{.function = HRNLIBSSH2_SESSION_FREE, .resultInt = LIBSSH2_ERROR_EAGAIN},
|
||||
{.function = HRNLIBSSH2_SESSION_BLOCK_DIRECTIONS, .resultInt = SSH2_NO_BLOCK_READING_WRITING},
|
||||
@ -4947,7 +4947,7 @@ testRun(void)
|
||||
{
|
||||
HRNLIBSSH2_MACRO_STARTUP(),
|
||||
{.function = HRNLIBSSH2_SFTP_SHUTDOWN, .resultInt = LIBSSH2_ERROR_NONE},
|
||||
{.function = HRNLIBSSH2_SESSION_DISCONNECT_EX, .param = "[11,\"pgbackrest instance shutdown\",\"\"]",
|
||||
{.function = HRNLIBSSH2_SESSION_DISCONNECT_EX, .param = "[11,\"pgBackRest instance shutdown\",\"\"]",
|
||||
.resultInt = LIBSSH2_ERROR_SOCKET_DISCONNECT},
|
||||
{.function = NULL},
|
||||
});
|
||||
@ -4968,7 +4968,7 @@ testRun(void)
|
||||
{
|
||||
HRNLIBSSH2_MACRO_STARTUP(),
|
||||
{.function = HRNLIBSSH2_SFTP_SHUTDOWN, .resultInt = LIBSSH2_ERROR_NONE},
|
||||
{.function = HRNLIBSSH2_SESSION_DISCONNECT_EX, .param = "[11,\"pgbackrest instance shutdown\",\"\"]",
|
||||
{.function = HRNLIBSSH2_SESSION_DISCONNECT_EX, .param = "[11,\"pgBackRest instance shutdown\",\"\"]",
|
||||
.resultInt = LIBSSH2_ERROR_EAGAIN},
|
||||
{.function = HRNLIBSSH2_SESSION_BLOCK_DIRECTIONS, .resultInt = SSH2_BLOCK_READING_WRITING},
|
||||
{.function = NULL},
|
||||
@ -4990,7 +4990,7 @@ testRun(void)
|
||||
{
|
||||
HRNLIBSSH2_MACRO_STARTUP(),
|
||||
{.function = HRNLIBSSH2_SFTP_SHUTDOWN, .resultInt = LIBSSH2_ERROR_NONE},
|
||||
{.function = HRNLIBSSH2_SESSION_DISCONNECT_EX, .param = "[11,\"pgbackrest instance shutdown\",\"\"]",
|
||||
{.function = HRNLIBSSH2_SESSION_DISCONNECT_EX, .param = "[11,\"pgBackRest instance shutdown\",\"\"]",
|
||||
.resultInt = LIBSSH2_ERROR_NONE},
|
||||
{.function = HRNLIBSSH2_SESSION_FREE, .resultInt = LIBSSH2_ERROR_SOCKET_DISCONNECT},
|
||||
{.function = NULL},
|
||||
@ -5012,7 +5012,7 @@ testRun(void)
|
||||
{
|
||||
HRNLIBSSH2_MACRO_STARTUP(),
|
||||
{.function = HRNLIBSSH2_SFTP_SHUTDOWN, .resultInt = LIBSSH2_ERROR_NONE},
|
||||
{.function = HRNLIBSSH2_SESSION_DISCONNECT_EX, .param = "[11,\"pgbackrest instance shutdown\",\"\"]",
|
||||
{.function = HRNLIBSSH2_SESSION_DISCONNECT_EX, .param = "[11,\"pgBackRest instance shutdown\",\"\"]",
|
||||
.resultInt = LIBSSH2_ERROR_NONE},
|
||||
{.function = HRNLIBSSH2_SESSION_FREE, .resultInt = LIBSSH2_ERROR_EAGAIN},
|
||||
{.function = HRNLIBSSH2_SESSION_BLOCK_DIRECTIONS, .resultInt = SSH2_BLOCK_READING_WRITING},
|
||||
|
Loading…
x
Reference in New Issue
Block a user