* Initialize some variables that are never used anyway.
* Use valid pointers instead of integers cast to void pointers when
calling pthread_setspecific().
ASTERISK-29711 #close
ASTERISK-29713 #close
Change-Id: I8728cd6f2f4b28e0e48113c5da450b768c2a6683
int status;
status = ast_threadstorage_set_ptr(&in_intercept_routine,
- in_intercept_mode ? (void *) 1 : (void *) 0);
+ in_intercept_mode ? &(int) { 1 } : NULL);
if (status) {
ast_log(LOG_ERROR, "Failed to set dialplan intercept mode\n");
}
return;
}
- if (ast_threadstorage_set_ptr(&in_safe_log, (void*)1)) {
+ if (ast_threadstorage_set_ptr(&in_safe_log, &(int) { 1 })) {
/* We've failed to set the flag that protects against
* recursion, so bail. */
return;
static struct ast_config *ast_config_internal_load(const char *filename, struct ast_config *cfg, int withcomments, const char *suggested_incl_file)
{
- char db[256];
- char table[256];
+ char db[256] = "";
+ char table[256] = "";
struct ast_config_engine *loader = &text_file_engine;
struct ast_config *result;