Add some debug
This commit is contained in:
parent
c4d4288b45
commit
fc494f4c9e
|
@ -105,7 +105,7 @@ void mv_buffer_rtow(struct algo_ctx* app_ctx, struct evt_core_fdinfo* from, stru
|
||||||
// 1. We get the packet buffer
|
// 1. We get the packet buffer
|
||||||
bp = g_hash_table_lookup (app_ctx->used_buffer, &from->fd);
|
bp = g_hash_table_lookup (app_ctx->used_buffer, &from->fd);
|
||||||
if (bp == NULL) {
|
if (bp == NULL) {
|
||||||
fprintf(stderr, "Unable to find a buffer for fd=%d url=%s", from->fd, from->url);
|
fprintf(stderr, "Unable to find a buffer for fd=%d url=%s in rtow\n", from->fd, from->url);
|
||||||
exit(EXIT_FAILURE);
|
exit(EXIT_FAILURE);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -127,7 +127,7 @@ void mv_buffer_rtof(struct algo_ctx* app_ctx, struct evt_core_fdinfo* from) {
|
||||||
// 1. We get the packet buffer
|
// 1. We get the packet buffer
|
||||||
bp = g_hash_table_lookup (app_ctx->used_buffer, &from->fd);
|
bp = g_hash_table_lookup (app_ctx->used_buffer, &from->fd);
|
||||||
if (bp == NULL) {
|
if (bp == NULL) {
|
||||||
fprintf(stderr, "Unable to find a buffer for fd=%d url=%s", from->fd, from->url);
|
fprintf(stderr, "Unable to find a buffer for fd=%d url=%s in rtof\n", from->fd, from->url);
|
||||||
}
|
}
|
||||||
g_hash_table_remove(app_ctx->used_buffer, &(from->fd));
|
g_hash_table_remove(app_ctx->used_buffer, &(from->fd));
|
||||||
|
|
||||||
|
@ -137,7 +137,7 @@ void mv_buffer_rtof(struct algo_ctx* app_ctx, struct evt_core_fdinfo* from) {
|
||||||
void mv_buffer_wtof(struct algo_ctx* app_ctx, struct evt_core_fdinfo* fdinfo) {
|
void mv_buffer_wtof(struct algo_ctx* app_ctx, struct evt_core_fdinfo* fdinfo) {
|
||||||
struct buffer_packet* bp = g_hash_table_lookup (app_ctx->used_buffer, &(fdinfo->fd));
|
struct buffer_packet* bp = g_hash_table_lookup (app_ctx->used_buffer, &(fdinfo->fd));
|
||||||
if (bp == NULL) {
|
if (bp == NULL) {
|
||||||
fprintf(stderr, "Unable to find a buffer for fd=%d url=%s", fdinfo->fd, fdinfo->url);
|
fprintf(stderr, "Unable to find a buffer for fd=%d url=%s in wtof\n", fdinfo->fd, fdinfo->url);
|
||||||
}
|
}
|
||||||
g_hash_table_remove(app_ctx->used_buffer, &(fdinfo->fd));
|
g_hash_table_remove(app_ctx->used_buffer, &(fdinfo->fd));
|
||||||
|
|
||||||
|
@ -166,7 +166,7 @@ void mv_buffer_atow(struct algo_ctx* app_ctx, void* from, struct evt_core_fdinfo
|
||||||
// 1. We get the buffer
|
// 1. We get the buffer
|
||||||
bp = g_hash_table_lookup (app_ctx->application_waiting, from);
|
bp = g_hash_table_lookup (app_ctx->application_waiting, from);
|
||||||
if (bp == NULL) {
|
if (bp == NULL) {
|
||||||
fprintf(stderr, "Unable to find this application buffer\n");
|
fprintf(stderr, "Unable to find this application buffer in atow for %s\n", to->url);
|
||||||
exit(EXIT_FAILURE);
|
exit(EXIT_FAILURE);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -188,7 +188,7 @@ void mv_buffer_atof(struct algo_ctx* app_ctx, void* from) {
|
||||||
// 1. Remove the buffer
|
// 1. Remove the buffer
|
||||||
bp = g_hash_table_lookup (app_ctx->application_waiting, from);
|
bp = g_hash_table_lookup (app_ctx->application_waiting, from);
|
||||||
if (bp == NULL) {
|
if (bp == NULL) {
|
||||||
fprintf(stderr, "Unable to find this application buffer\n");
|
fprintf(stderr, "Unable to find this application buffer in atof\n");
|
||||||
exit(EXIT_FAILURE);
|
exit(EXIT_FAILURE);
|
||||||
}
|
}
|
||||||
g_hash_table_remove (app_ctx->application_waiting, from);
|
g_hash_table_remove (app_ctx->application_waiting, from);
|
||||||
|
|
Loading…
Reference in a new issue