X-Git-Url: https://git.m6w6.name/?p=m6w6%2Fext-psi;a=blobdiff_plain;f=src%2Fdata.h;h=5356a7ec43d858f8a2f1050a60a0f1291b81f4aa;hp=3c48716cd21820af4b1d4e30f657e8a3479c04e9;hb=6509a2053456d0e63b6f383b757289d3016ed1a5;hpb=9bcb1df0786a8193d65949c857baaba2f4296e84 diff --git a/src/data.h b/src/data.h index 3c48716..5356a7e 100644 --- a/src/data.h +++ b/src/data.h @@ -36,7 +36,7 @@ #include #define PSI_DEBUG_PRINT(ctx, msg, ...) do { \ - if (PSI_DATA(ctx)->flags & PSI_DEBUG) { \ + if ((ctx) && (PSI_DATA(ctx)->flags & PSI_DEBUG)) { \ fprintf(stderr, msg, __VA_ARGS__); \ } \ } while(0)