[WIP] Add some debug, correctly.

This commit is contained in:
Nick Couchman 2020-04-05 14:08:05 -04:00
parent 64a463738b
commit 7a624c4d86
3 changed files with 8 additions and 4 deletions

View File

@ -37,7 +37,8 @@ void guac_rdpsnd_process_receive(guac_rdp_common_svc* svc,
/* Check that we at least have a header. */ /* Check that we at least have a header. */
if (Stream_GetRemainingLength(input_stream) < sizeof(header)) { if (Stream_GetRemainingLength(input_stream) < sizeof(header)) {
guac_client_log(svc->client, "Not enough bytes to process sound header."); guac_client_log(svc->client, GUAC_LOG_WARNING,
"Not enough bytes to process sound header.");
return; return;
} }
@ -48,7 +49,8 @@ void guac_rdpsnd_process_receive(guac_rdp_common_svc* svc,
/* Check that the body_size actually exists in the input stream. */ /* Check that the body_size actually exists in the input stream. */
if (Stream_GetRemainingLength(input_stream) < header.body_size) { if (Stream_GetRemainingLength(input_stream) < header.body_size) {
guac_client_log(svc->client, "Not enough bytes to process sound body."); guac_client_log(svc->client, GUAC_LOG_WARNING,
"Not enough bytes to process sound body.");
return; return;
} }

View File

@ -268,7 +268,8 @@ void guac_rdp_ai_process_formats(guac_client* client,
/* Check amount of data. */ /* Check amount of data. */
if (Stream_GetRemainingLength(stream) < (8 + num_formats)) { if (Stream_GetRemainingLength(stream) < (8 + num_formats)) {
guac_client_log(client, "Not enough bytes to process supported sound formats."); guac_client_log(client, GUAC_LOG_WARNING,
"Not enough bytes to process supported sound formats.");
return; return;
} }

View File

@ -58,7 +58,8 @@ static void guac_rdp_ai_handle_data(guac_client* client,
/* If not enough data, bail out. */ /* If not enough data, bail out. */
if (Stream_GetRemainingLength(stream) < 1) { if (Stream_GetRemainingLength(stream) < 1) {
guac_client_log(client, "Not enough data in stream for incoming audio."); guac_client_log(client, GUAC_LOG_WARNING,
"Not enough data in stream for incoming audio.");
return; return;
} }