# HG changeset patch # User Tero Marttila # Date 1262271682 -7200 # Node ID 47f15166e25ab11aaf4468eeebc4a2dd47e4398c # Parent f0d1011e88745dcdd7e4b9b1a14e022fac9cea8b misc diff -r f0d1011e8874 -r 47f15166e25a src/lib/ctx.c --- a/src/lib/ctx.c Thu Dec 31 16:53:07 2009 +0200 +++ b/src/lib/ctx.c Thu Dec 31 17:01:22 2009 +0200 @@ -6,6 +6,9 @@ #include #include // for perror +/** + * Wrapper around pthread_mutex_unlock for use with pthread_cleanup_push + */ static void pt_mutex_unlock (void *arg) { pthread_mutex_t *mutex = arg; @@ -226,10 +229,11 @@ struct pt_work *work; // check state + // XXX: this is kind of retarded, because pt_ctx_shutdown/work should only be called from the same thread... if (!ctx->running) RETURN_ERROR(PT_ERR_CTX_SHUTDOWN); - // construct + // alloc if ((work = calloc(1, sizeof(*work))) == NULL) RETURN_ERROR(PT_ERR_MEM); diff -r f0d1011e8874 -r 47f15166e25a src/lib/tile.c --- a/src/lib/tile.c Thu Dec 31 16:53:07 2009 +0200 +++ b/src/lib/tile.c Thu Dec 31 17:01:22 2009 +0200 @@ -149,3 +149,4 @@ free(tile); } +