Lines 112-121
FILE * univention_debug_init(const char *logfile, enum uv_debug_flag_flush flush
|
Link Here
|
---|
|
112 |
if ((univention_debug_file = fopen(logfile, "a+")) == NULL) { |
112 |
if ((univention_debug_file = fopen(logfile, "a+")) == NULL) { |
113 |
free(univention_debug_level); |
113 |
free(univention_debug_level); |
114 |
univention_debug_level = NULL; |
114 |
univention_debug_level = NULL; |
115 |
fprintf(stderr, "Could not open logfile \"%s\"\n", univention_debug_filename); |
115 |
fprintf(stderr, "Could not open logfile \"%s\"\n", logfile); |
116 |
return NULL; |
116 |
return NULL; |
117 |
} |
117 |
} |
118 |
} |
118 |
} |
|
|
119 |
univention_debug_filename = logfile; |
119 |
|
120 |
|
120 |
univention_debug_flush = flush; |
121 |
univention_debug_flush = flush; |
121 |
univention_debug_function = function; |
122 |
univention_debug_function = function; |
Lines 178-183
void univention_debug_end(const char *s)
|
Link Here
|
---|
|
178 |
|
179 |
|
179 |
void univention_debug_reopen(void) |
180 |
void univention_debug_reopen(void) |
180 |
{ |
181 |
{ |
|
|
182 |
if (!univention_debug_ready) { |
183 |
return; |
184 |
} |
185 |
|
181 |
if (univention_debug_file == stderr || univention_debug_file == stdout) |
186 |
if (univention_debug_file == stderr || univention_debug_file == stdout) |
182 |
return; |
187 |
return; |
183 |
if (univention_debug_file != NULL) { |
188 |
if (univention_debug_file != NULL) { |