diff options
| author | 2019-11-20 01:39:46 +0100 | |
|---|---|---|
| committer | 2019-11-20 01:39:46 +0100 | |
| commit | 43852c74160394c0be876945b85c0656fa2bff81 (patch) | |
| tree | 00c22f445e13fadf344d7977e00cf2b2dee34856 /tools | |
| parent | af91dc6376946daffd5c9ece916d9f33af828890 (diff) | |
| download | libimobiledevice-43852c74160394c0be876945b85c0656fa2bff81.tar.gz libimobiledevice-43852c74160394c0be876945b85c0656fa2bff81.tar.bz2 | |
debugserver: Return size of the returned buffer
Diffstat (limited to 'tools')
| -rw-r--r-- | tools/idevicedebug.c | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/tools/idevicedebug.c b/tools/idevicedebug.c index c7508e3..6c2f5cf 100644 --- a/tools/idevicedebug.c +++ b/tools/idevicedebug.c | |||
| @@ -127,7 +127,7 @@ static debugserver_error_t debugserver_client_handle_response(debugserver_client | |||
| 127 | 127 | ||
| 128 | /* send reply */ | 128 | /* send reply */ |
| 129 | debugserver_command_new("OK", 0, NULL, &command); | 129 | debugserver_command_new("OK", 0, NULL, &command); |
| 130 | dres = debugserver_client_send_command(client, command, response); | 130 | dres = debugserver_client_send_command(client, command, response, NULL); |
| 131 | debug_info("result: %d", dres); | 131 | debug_info("result: %d", dres); |
| 132 | debugserver_command_free(command); | 132 | debugserver_command_free(command); |
| 133 | command = NULL; | 133 | command = NULL; |
| @@ -153,7 +153,7 @@ static debugserver_error_t debugserver_client_handle_response(debugserver_client | |||
| 153 | 153 | ||
| 154 | /* send reply */ | 154 | /* send reply */ |
| 155 | debugserver_command_new("OK", 0, NULL, &command); | 155 | debugserver_command_new("OK", 0, NULL, &command); |
| 156 | dres = debugserver_client_send_command(client, command, response); | 156 | dres = debugserver_client_send_command(client, command, response, NULL); |
| 157 | debug_info("result: %d", dres); | 157 | debug_info("result: %d", dres); |
| 158 | debugserver_command_free(command); | 158 | debugserver_command_free(command); |
| 159 | command = NULL; | 159 | command = NULL; |
| @@ -166,7 +166,7 @@ static debugserver_error_t debugserver_client_handle_response(debugserver_client | |||
| 166 | 166 | ||
| 167 | /* no command */ | 167 | /* no command */ |
| 168 | debugserver_command_new("OK", 0, NULL, &command); | 168 | debugserver_command_new("OK", 0, NULL, &command); |
| 169 | dres = debugserver_client_send_command(client, command, response); | 169 | dres = debugserver_client_send_command(client, command, response, NULL); |
| 170 | debug_info("result: %d", dres); | 170 | debug_info("result: %d", dres); |
| 171 | debugserver_command_free(command); | 171 | debugserver_command_free(command); |
| 172 | command = NULL; | 172 | command = NULL; |
| @@ -342,7 +342,7 @@ int main(int argc, char *argv[]) | |||
| 342 | if (debug_level) { | 342 | if (debug_level) { |
| 343 | debug_info("Setting logging bitmask..."); | 343 | debug_info("Setting logging bitmask..."); |
| 344 | debugserver_command_new("QSetLogging:bitmask=LOG_ALL|LOG_RNB_REMOTE|LOG_RNB_PACKETS", 0, NULL, &command); | 344 | debugserver_command_new("QSetLogging:bitmask=LOG_ALL|LOG_RNB_REMOTE|LOG_RNB_PACKETS", 0, NULL, &command); |
| 345 | dres = debugserver_client_send_command(debugserver_client, command, &response); | 345 | dres = debugserver_client_send_command(debugserver_client, command, &response, NULL); |
| 346 | debugserver_command_free(command); | 346 | debugserver_command_free(command); |
| 347 | command = NULL; | 347 | command = NULL; |
| 348 | if (response) { | 348 | if (response) { |
| @@ -360,7 +360,7 @@ int main(int argc, char *argv[]) | |||
| 360 | char* packet_size[2] = {strdup("1024"), NULL}; | 360 | char* packet_size[2] = {strdup("1024"), NULL}; |
| 361 | debugserver_command_new("QSetMaxPacketSize:", 1, packet_size, &command); | 361 | debugserver_command_new("QSetMaxPacketSize:", 1, packet_size, &command); |
| 362 | free(packet_size[0]); | 362 | free(packet_size[0]); |
| 363 | dres = debugserver_client_send_command(debugserver_client, command, &response); | 363 | dres = debugserver_client_send_command(debugserver_client, command, &response, NULL); |
| 364 | debugserver_command_free(command); | 364 | debugserver_command_free(command); |
| 365 | command = NULL; | 365 | command = NULL; |
| 366 | if (response) { | 366 | if (response) { |
| @@ -376,7 +376,7 @@ int main(int argc, char *argv[]) | |||
| 376 | debug_info("Setting working directory..."); | 376 | debug_info("Setting working directory..."); |
| 377 | char* working_dir[2] = {working_directory, NULL}; | 377 | char* working_dir[2] = {working_directory, NULL}; |
| 378 | debugserver_command_new("QSetWorkingDir:", 1, working_dir, &command); | 378 | debugserver_command_new("QSetWorkingDir:", 1, working_dir, &command); |
| 379 | dres = debugserver_client_send_command(debugserver_client, command, &response); | 379 | dres = debugserver_client_send_command(debugserver_client, command, &response, NULL); |
| 380 | debugserver_command_free(command); | 380 | debugserver_command_free(command); |
| 381 | command = NULL; | 381 | command = NULL; |
| 382 | if (response) { | 382 | if (response) { |
| @@ -417,7 +417,7 @@ int main(int argc, char *argv[]) | |||
| 417 | /* check if launch succeeded */ | 417 | /* check if launch succeeded */ |
| 418 | debug_info("Checking if launch succeeded..."); | 418 | debug_info("Checking if launch succeeded..."); |
| 419 | debugserver_command_new("qLaunchSuccess", 0, NULL, &command); | 419 | debugserver_command_new("qLaunchSuccess", 0, NULL, &command); |
| 420 | dres = debugserver_client_send_command(debugserver_client, command, &response); | 420 | dres = debugserver_client_send_command(debugserver_client, command, &response, NULL); |
| 421 | debugserver_command_free(command); | 421 | debugserver_command_free(command); |
| 422 | command = NULL; | 422 | command = NULL; |
| 423 | if (response) { | 423 | if (response) { |
| @@ -432,7 +432,7 @@ int main(int argc, char *argv[]) | |||
| 432 | /* set thread */ | 432 | /* set thread */ |
| 433 | debug_info("Setting thread..."); | 433 | debug_info("Setting thread..."); |
| 434 | debugserver_command_new("Hc0", 0, NULL, &command); | 434 | debugserver_command_new("Hc0", 0, NULL, &command); |
| 435 | dres = debugserver_client_send_command(debugserver_client, command, &response); | 435 | dres = debugserver_client_send_command(debugserver_client, command, &response, NULL); |
| 436 | debugserver_command_free(command); | 436 | debugserver_command_free(command); |
| 437 | command = NULL; | 437 | command = NULL; |
| 438 | if (response) { | 438 | if (response) { |
| @@ -447,7 +447,7 @@ int main(int argc, char *argv[]) | |||
| 447 | /* continue running process */ | 447 | /* continue running process */ |
| 448 | debug_info("Continue running process..."); | 448 | debug_info("Continue running process..."); |
| 449 | debugserver_command_new("c", 0, NULL, &command); | 449 | debugserver_command_new("c", 0, NULL, &command); |
| 450 | dres = debugserver_client_send_command(debugserver_client, command, &response); | 450 | dres = debugserver_client_send_command(debugserver_client, command, &response, NULL); |
| 451 | debugserver_command_free(command); | 451 | debugserver_command_free(command); |
| 452 | command = NULL; | 452 | command = NULL; |
| 453 | 453 | ||
| @@ -470,7 +470,7 @@ int main(int argc, char *argv[]) | |||
| 470 | /* kill process after we finished */ | 470 | /* kill process after we finished */ |
| 471 | debug_info("Killing process..."); | 471 | debug_info("Killing process..."); |
| 472 | debugserver_command_new("k", 0, NULL, &command); | 472 | debugserver_command_new("k", 0, NULL, &command); |
| 473 | dres = debugserver_client_send_command(debugserver_client, command, &response); | 473 | dres = debugserver_client_send_command(debugserver_client, command, &response, NULL); |
| 474 | debugserver_command_free(command); | 474 | debugserver_command_free(command); |
| 475 | command = NULL; | 475 | command = NULL; |
| 476 | if (response) { | 476 | if (response) { |
