Threaded IO: hide more debugging printfs under conditional.

This commit is contained in:
antirez 2019-03-27 18:59:39 +01:00
parent 9814b2a5f3
commit 74591fb5bd

View File

@ -2547,7 +2547,7 @@ void initThreadedIO(void) {
} }
void startThreadedIO(void) { void startThreadedIO(void) {
printf("S"); fflush(stdout); if (tio_debug) printf("S"); fflush(stdout);
if (tio_debug) printf("--- STARTING THREADED IO ---\n"); if (tio_debug) printf("--- STARTING THREADED IO ---\n");
serverAssert(io_threads_active == 0); serverAssert(io_threads_active == 0);
for (int j = 0; j < server.io_threads_num; j++) for (int j = 0; j < server.io_threads_num; j++)
@ -2556,7 +2556,7 @@ void startThreadedIO(void) {
} }
void stopThreadedIO(void) { void stopThreadedIO(void) {
printf("E"); fflush(stdout); if (tio_debug) printf("E"); fflush(stdout);
if (tio_debug) printf("--- STOPPING THREADED IO ---\n"); if (tio_debug) printf("--- STOPPING THREADED IO ---\n");
serverAssert(io_threads_active == 1); serverAssert(io_threads_active == 1);
for (int j = 0; j < server.io_threads_num; j++) for (int j = 0; j < server.io_threads_num; j++)