#include "asterisk.h"
#include <sys/stat.h>
#include <errno.h>
#include <time.h>
#include <utime.h>
#include <stdlib.h>
#include <unistd.h>
#include <dirent.h>
#include <string.h>
#include <stdio.h>
#include "asterisk/lock.h"
#include "asterisk/file.h"
#include "asterisk/logger.h"
#include "asterisk/channel.h"
#include "asterisk/callerid.h"
#include "asterisk/pbx.h"
#include "asterisk/module.h"
#include "asterisk/options.h"
#include "asterisk/utils.h"
Go to the source code of this file.
Data Structures | |
struct | outgoing |
Enumerations | |
enum | { SPOOL_FLAG_ALWAYS_DELETE = (1 << 0), SPOOL_FLAG_ARCHIVE = (1 << 1) } |
Functions | |
static int | apply_outgoing (struct outgoing *o, char *fn, FILE *f) |
AST_MODULE_INFO_STANDARD (ASTERISK_GPL_KEY,"Outgoing Spool Support") | |
static void * | attempt_thread (void *data) |
static void | free_outgoing (struct outgoing *o) |
static void | init_outgoing (struct outgoing *o) |
static void | launch_service (struct outgoing *o) |
static int | load_module (void) |
static int | remove_from_queue (struct outgoing *o, const char *status) |
Remove a call file from the outgoing queue optionally moving it in the archive dir. | |
static void | safe_append (struct outgoing *o, time_t now, char *s) |
static int | scan_service (char *fn, time_t now, time_t atime) |
static void * | scan_thread (void *unused) |
static int | unload_module (void) |
Variables | |
static char | qdir [255] |
static char | qdonedir [255] |
Definition in file pbx_spool.c.
anonymous enum |
SPOOL_FLAG_ALWAYS_DELETE | Always delete the call file after a call succeeds or the maximum number of retries is exceeded, even if the modification time of the call file is in the future. |
SPOOL_FLAG_ARCHIVE |
Definition at line 56 of file pbx_spool.c.
00056 { 00057 /*! Always delete the call file after a call succeeds or the 00058 * maximum number of retries is exceeded, even if the 00059 * modification time of the call file is in the future. 00060 */ 00061 SPOOL_FLAG_ALWAYS_DELETE = (1 << 0), 00062 /* Don't unlink the call file after processing, move in qdonedir */ 00063 SPOOL_FLAG_ARCHIVE = (1 << 1) 00064 };
static int apply_outgoing | ( | struct outgoing * | o, | |
char * | fn, | |||
FILE * | f | |||
) | [static] |
Definition at line 130 of file pbx_spool.c.
References outgoing::account, outgoing::app, ast_callerid_split(), ast_log(), ast_set2_flag, ast_strlen_zero(), ast_true(), ast_variable_new(), outgoing::callingpid, outgoing::cid_name, outgoing::cid_num, outgoing::context, outgoing::data, outgoing::dest, outgoing::exten, outgoing::fn, lineno, LOG_NOTICE, LOG_WARNING, outgoing::maxretries, outgoing::message, ast_variable::next, outgoing::options, outgoing::pdu, outgoing::priority, outgoing::retries, outgoing::retrytime, SPOOL_FLAG_ALWAYS_DELETE, SPOOL_FLAG_ARCHIVE, strsep(), outgoing::tech, var, outgoing::vars, and outgoing::waittime.
Referenced by scan_service().
00131 { 00132 char buf[256]; 00133 char *c, *c2; 00134 int lineno = 0; 00135 struct ast_variable *var; 00136 00137 while(fgets(buf, sizeof(buf), f)) { 00138 lineno++; 00139 /* Trim comments */ 00140 c = buf; 00141 while ((c = strchr(c, '#'))) { 00142 if ((c == buf) || (*(c-1) == ' ') || (*(c-1) == '\t')) 00143 *c = '\0'; 00144 else 00145 c++; 00146 } 00147 00148 c = buf; 00149 while ((c = strchr(c, ';'))) { 00150 if ((c > buf) && (c[-1] == '\\')) { 00151 memmove(c - 1, c, strlen(c) + 1); 00152 c++; 00153 } else { 00154 *c = '\0'; 00155 break; 00156 } 00157 } 00158 00159 /* Trim trailing white space */ 00160 while(!ast_strlen_zero(buf) && buf[strlen(buf) - 1] < 33) 00161 buf[strlen(buf) - 1] = '\0'; 00162 if (!ast_strlen_zero(buf)) { 00163 c = strchr(buf, ':'); 00164 if (c) { 00165 *c = '\0'; 00166 c++; 00167 while ((*c) && (*c < 33)) 00168 c++; 00169 #if 0 00170 printf("'%s' is '%s' at line %d\n", buf, c, lineno); 00171 #endif 00172 if (!strcasecmp(buf, "channel")) { 00173 ast_copy_string(o->tech, c, sizeof(o->tech)); 00174 if ((c2 = strchr(o->tech, '/'))) { 00175 *c2 = '\0'; 00176 c2++; 00177 ast_copy_string(o->dest, c2, sizeof(o->dest)); 00178 } else { 00179 ast_log(LOG_NOTICE, "Channel should be in form Tech/Dest at line %d of %s\n", lineno, fn); 00180 o->tech[0] = '\0'; 00181 } 00182 } else if (!strcasecmp(buf, "callerid")) { 00183 ast_callerid_split(c, o->cid_name, sizeof(o->cid_name), o->cid_num, sizeof(o->cid_num)); 00184 } else if (!strcasecmp(buf, "application")) { 00185 ast_copy_string(o->app, c, sizeof(o->app)); 00186 } else if (!strcasecmp(buf, "data")) { 00187 ast_copy_string(o->data, c, sizeof(o->data)); 00188 } else if (!strcasecmp(buf, "message")) { 00189 strncpy(o->message, c, sizeof(o->message) - 1); 00190 } else if (!strcasecmp(buf, "pdu")) { 00191 strncpy(o->pdu, c, sizeof(o->pdu) - 1); 00192 } else if (!strcasecmp(buf, "maxretries")) { 00193 if (sscanf(c, "%d", &o->maxretries) != 1) { 00194 ast_log(LOG_WARNING, "Invalid max retries at line %d of %s\n", lineno, fn); 00195 o->maxretries = 0; 00196 } 00197 } else if (!strcasecmp(buf, "context")) { 00198 ast_copy_string(o->context, c, sizeof(o->context)); 00199 } else if (!strcasecmp(buf, "extension")) { 00200 ast_copy_string(o->exten, c, sizeof(o->exten)); 00201 } else if (!strcasecmp(buf, "priority")) { 00202 if ((sscanf(c, "%d", &o->priority) != 1) || (o->priority < 1)) { 00203 ast_log(LOG_WARNING, "Invalid priority at line %d of %s\n", lineno, fn); 00204 o->priority = 1; 00205 } 00206 } else if (!strcasecmp(buf, "retrytime")) { 00207 if ((sscanf(c, "%d", &o->retrytime) != 1) || (o->retrytime < 1)) { 00208 ast_log(LOG_WARNING, "Invalid retrytime at line %d of %s\n", lineno, fn); 00209 o->retrytime = 300; 00210 } 00211 } else if (!strcasecmp(buf, "waittime")) { 00212 if ((sscanf(c, "%d", &o->waittime) != 1) || (o->waittime < 1)) { 00213 ast_log(LOG_WARNING, "Invalid waittime at line %d of %s\n", lineno, fn); 00214 o->waittime = 45; 00215 } 00216 } else if (!strcasecmp(buf, "retry")) { 00217 o->retries++; 00218 } else if (!strcasecmp(buf, "startretry")) { 00219 if (sscanf(c, "%ld", &o->callingpid) != 1) { 00220 ast_log(LOG_WARNING, "Unable to retrieve calling PID!\n"); 00221 o->callingpid = 0; 00222 } 00223 } else if (!strcasecmp(buf, "endretry") || !strcasecmp(buf, "abortretry")) { 00224 o->callingpid = 0; 00225 o->retries++; 00226 } else if (!strcasecmp(buf, "delayedretry")) { 00227 } else if (!strcasecmp(buf, "setvar") || !strcasecmp(buf, "set")) { 00228 c2 = c; 00229 strsep(&c2, "="); 00230 if (c2) { 00231 var = ast_variable_new(c, c2); 00232 if (var) { 00233 var->next = o->vars; 00234 o->vars = var; 00235 } 00236 } else 00237 ast_log(LOG_WARNING, "Malformed \"%s\" argument. Should be \"%s: variable=value\"\n", buf, buf); 00238 } else if (!strcasecmp(buf, "account")) { 00239 ast_copy_string(o->account, c, sizeof(o->account)); 00240 } else if (!strcasecmp(buf, "alwaysdelete")) { 00241 ast_set2_flag(&o->options, ast_true(c), SPOOL_FLAG_ALWAYS_DELETE); 00242 } else if (!strcasecmp(buf, "archive")) { 00243 ast_set2_flag(&o->options, ast_true(c), SPOOL_FLAG_ARCHIVE); 00244 } else { 00245 ast_log(LOG_WARNING, "Unknown keyword '%s' at line %d of %s\n", buf, lineno, fn); 00246 } 00247 } else 00248 ast_log(LOG_NOTICE, "Syntax error at line %d of %s\n", lineno, fn); 00249 } 00250 } 00251 ast_copy_string(o->fn, fn, sizeof(o->fn)); 00252 if (ast_strlen_zero(o->tech) || ast_strlen_zero(o->dest) || ((ast_strlen_zero(o->app) && ast_strlen_zero(o->exten) && ast_strlen_zero(o->message) && ast_strlen_zero(o->pdu)))) { 00253 ast_log(LOG_WARNING, "At least one of app or extension (or keyword message/pdu)must be specified, along with tech and dest in file %s\n", fn); 00254 return -1; 00255 } 00256 return 0; 00257 }
AST_MODULE_INFO_STANDARD | ( | ASTERISK_GPL_KEY | , | |
"Outgoing Spool Support" | ||||
) |
static void* attempt_thread | ( | void * | data | ) | [static] |
Definition at line 335 of file pbx_spool.c.
References outgoing::account, outgoing::app, ast_channel_reason2str(), AST_FORMAT_SLINEAR, ast_log(), ast_pbx_outgoing_app(), ast_pbx_outgoing_exten(), ast_send_message(), ast_strlen_zero(), ast_verbose(), outgoing::cid_name, outgoing::cid_num, outgoing::context, outgoing::data, outgoing::dest, outgoing::exten, free_outgoing(), LOG_EVENT, LOG_NOTICE, outgoing::maxretries, outgoing::message, option_verbose, outgoing::pdu, outgoing::priority, remove_from_queue(), outgoing::retries, safe_append(), outgoing::tech, outgoing::vars, VERBOSE_PREFIX_2, VERBOSE_PREFIX_3, and outgoing::waittime.
Referenced by launch_service().
00336 { 00337 struct outgoing *o = data; 00338 int res, reason; 00339 if (!ast_strlen_zero(o->app)) { 00340 if (option_verbose > 2) 00341 ast_verbose(VERBOSE_PREFIX_3 "Attempting call on %s/%s for application %s(%s) (Retry %d)\n", o->tech, o->dest, o->app, o->data, o->retries); 00342 res = ast_pbx_outgoing_app(o->tech, AST_FORMAT_SLINEAR, o->dest, o->waittime * 1000, o->app, o->data, &reason, 2 /* wait to finish */, o->cid_num, o->cid_name, o->vars, o->account, NULL); 00343 } else if (!ast_strlen_zero(o->message)) { 00344 if (option_verbose > 2) 00345 ast_verbose(VERBOSE_PREFIX_3 "Attempting to send message on %s/%s (Retry %d)\n", o->tech, o->dest, o->retries); 00346 res = ast_send_message(o->tech, o->dest, o->dest, (ast_strlen_zero(o->cid_name) ? o->cid_num : o->cid_name), o->message, 0); 00347 } else if (!ast_strlen_zero(o->pdu)) { 00348 if (option_verbose > 2) 00349 ast_verbose(VERBOSE_PREFIX_3 "Attempting to send message in PDU format on %s/%s (Retry %d)\n", o->tech, o->dest, o->retries); 00350 res = ast_send_message(o->tech, o->dest, o->dest, (ast_strlen_zero(o->cid_name) ? o->cid_num : o->cid_name), o->pdu, 1); 00351 } else { 00352 if (option_verbose > 2) 00353 ast_verbose(VERBOSE_PREFIX_3 "Attempting call on %s/%s for %s@%s:%d (Retry %d)\n", o->tech, o->dest, o->exten, o->context,o->priority, o->retries); 00354 res = ast_pbx_outgoing_exten(o->tech, AST_FORMAT_SLINEAR, o->dest, o->waittime * 1000, o->context, o->exten, o->priority, &reason, 2 /* wait to finish */, o->cid_num, o->cid_name, o->vars, o->account, NULL); 00355 } 00356 if (res) { 00357 ast_log(LOG_NOTICE, "Call failed to go through, reason (%d) %s\n", reason, ast_channel_reason2str(reason)); 00358 if (o->retries >= o->maxretries + 1) { 00359 /* Max retries exceeded */ 00360 ast_log(LOG_EVENT, "Queued call to %s/%s expired without completion after %d attempt%s\n", o->tech, o->dest, o->retries - 1, ((o->retries - 1) != 1) ? "s" : ""); 00361 remove_from_queue(o, "Expired"); 00362 } else { 00363 /* Notate that the call is still active */ 00364 safe_append(o, time(NULL), "EndRetry"); 00365 } 00366 } else { 00367 if (!ast_strlen_zero(o->message)) { 00368 if (option_verbose > 2) 00369 ast_verbose(VERBOSE_PREFIX_2 "Message sent to %s/%s\n", o->tech, o->dest); 00370 } else { 00371 ast_log(LOG_NOTICE, "Call completed to %s/%s\n", o->tech, o->dest); 00372 ast_log(LOG_EVENT, "Queued call to %s/%s completed\n", o->tech, o->dest); 00373 } 00374 remove_from_queue(o, "Completed"); 00375 } 00376 free_outgoing(o); 00377 return NULL; 00378 }
static void free_outgoing | ( | struct outgoing * | o | ) | [static] |
Definition at line 125 of file pbx_spool.c.
References free.
Referenced by attempt_thread(), launch_service(), and scan_service().
00126 { 00127 free(o); 00128 }
static void init_outgoing | ( | struct outgoing * | o | ) | [static] |
Definition at line 116 of file pbx_spool.c.
References ast_set_flag, outgoing::options, outgoing::priority, outgoing::retrytime, SPOOL_FLAG_ALWAYS_DELETE, and outgoing::waittime.
Referenced by scan_service().
00117 { 00118 memset(o, 0, sizeof(struct outgoing)); 00119 o->priority = 1; 00120 o->retrytime = 300; 00121 o->waittime = 45; 00122 ast_set_flag(&o->options, SPOOL_FLAG_ALWAYS_DELETE); 00123 }
static void launch_service | ( | struct outgoing * | o | ) | [static] |
Definition at line 380 of file pbx_spool.c.
References ast_log(), ast_pthread_create, attempt_thread(), free_outgoing(), LOG_WARNING, and t.
Referenced by scan_service().
00381 { 00382 pthread_t t; 00383 pthread_attr_t attr; 00384 int ret; 00385 pthread_attr_init(&attr); 00386 pthread_attr_setdetachstate(&attr, PTHREAD_CREATE_DETACHED); 00387 if ((ret = ast_pthread_create(&t,&attr,attempt_thread, o)) != 0) { 00388 ast_log(LOG_WARNING, "Unable to create thread :( (returned error: %d)\n", ret); 00389 free_outgoing(o); 00390 } 00391 pthread_attr_destroy(&attr); 00392 }
static int load_module | ( | void | ) | [static] |
Definition at line 507 of file pbx_spool.c.
References ast_config_AST_SPOOL_DIR, ast_log(), ast_pthread_create_background, errno, LOG_WARNING, scan_thread(), and thread.
00508 { 00509 pthread_t thread; 00510 pthread_attr_t attr; 00511 int ret; 00512 snprintf(qdir, sizeof(qdir), "%s/%s", ast_config_AST_SPOOL_DIR, "outgoing"); 00513 if (mkdir(qdir, 0700) && (errno != EEXIST)) { 00514 ast_log(LOG_WARNING, "Unable to create queue directory %s -- outgoing spool disabled\n", qdir); 00515 return 0; 00516 } 00517 snprintf(qdonedir, sizeof(qdir), "%s/%s", ast_config_AST_SPOOL_DIR, "outgoing_done"); 00518 pthread_attr_init(&attr); 00519 pthread_attr_setdetachstate(&attr, PTHREAD_CREATE_DETACHED); 00520 if ((ret = ast_pthread_create_background(&thread,&attr,scan_thread, NULL)) != 0) { 00521 ast_log(LOG_WARNING, "Unable to create thread :( (returned error: %d)\n", ret); 00522 return -1; 00523 } 00524 pthread_attr_destroy(&attr); 00525 return 0; 00526 }
static int remove_from_queue | ( | struct outgoing * | o, | |
const char * | status | |||
) | [static] |
Remove a call file from the outgoing queue optionally moving it in the archive dir.
o | the pointer to outgoing struct | |
status | the exit status of the call. Can be "Completed", "Failed" or "Expired" |
Definition at line 286 of file pbx_spool.c.
References ast_log(), ast_test_flag, errno, f, outgoing::fn, LOG_WARNING, outgoing::options, SPOOL_FLAG_ALWAYS_DELETE, and SPOOL_FLAG_ARCHIVE.
00287 { 00288 int fd; 00289 FILE *f; 00290 char newfn[256]; 00291 const char *bname; 00292 00293 if (!ast_test_flag(&o->options, SPOOL_FLAG_ALWAYS_DELETE)) { 00294 struct stat current_file_status; 00295 00296 if (!stat(o->fn, ¤t_file_status)) 00297 if (time(NULL) < current_file_status.st_mtime) 00298 return 0; 00299 } 00300 00301 if (!ast_test_flag(&o->options, SPOOL_FLAG_ARCHIVE)) { 00302 unlink(o->fn); 00303 return 0; 00304 } 00305 if (mkdir(qdonedir, 0700) && (errno != EEXIST)) { 00306 ast_log(LOG_WARNING, "Unable to create queue directory %s -- outgoing spool archiving disabled\n", qdonedir); 00307 unlink(o->fn); 00308 return -1; 00309 } 00310 fd = open(o->fn, O_WRONLY|O_APPEND); 00311 if (fd > -1) { 00312 f = fdopen(fd, "a"); 00313 if (f) { 00314 fprintf(f, "Status: %s\n", status); 00315 fclose(f); 00316 } else 00317 close(fd); 00318 } 00319 00320 bname = strrchr(o->fn,'/'); 00321 if (bname == NULL) 00322 bname = o->fn; 00323 else 00324 bname++; 00325 snprintf(newfn, sizeof(newfn), "%s/%s", qdonedir, bname); 00326 /* a existing call file the archive dir is overwritten */ 00327 unlink(newfn); 00328 if (rename(o->fn, newfn) != 0) { 00329 unlink(o->fn); 00330 return -1; 00331 } else 00332 return 0; 00333 }
static void safe_append | ( | struct outgoing * | o, | |
time_t | now, | |||
char * | s | |||
) | [static] |
Definition at line 259 of file pbx_spool.c.
References ast_log(), ast_mainpid, errno, f, outgoing::fn, LOG_WARNING, outgoing::retries, and outgoing::retrytime.
Referenced by attempt_thread(), and scan_service().
00260 { 00261 int fd; 00262 FILE *f; 00263 struct utimbuf tbuf; 00264 fd = open(o->fn, O_WRONLY|O_APPEND); 00265 if (fd > -1) { 00266 f = fdopen(fd, "a"); 00267 if (f) { 00268 fprintf(f, "\n%s: %ld %d (%ld)\n", s, (long)ast_mainpid, o->retries, (long) now); 00269 fclose(f); 00270 } else 00271 close(fd); 00272 /* Update the file time */ 00273 tbuf.actime = now; 00274 tbuf.modtime = now + o->retrytime; 00275 if (utime(o->fn, &tbuf)) 00276 ast_log(LOG_WARNING, "Unable to set utime on %s: %s\n", o->fn, strerror(errno)); 00277 } 00278 }
static int scan_service | ( | char * | fn, | |
time_t | now, | |||
time_t | atime | |||
) | [static] |
Definition at line 394 of file pbx_spool.c.
References apply_outgoing(), ast_log(), ast_mainpid, outgoing::callingpid, outgoing::dest, errno, f, outgoing::fn, free_outgoing(), init_outgoing(), launch_service(), LOG_DEBUG, LOG_EVENT, LOG_WARNING, malloc, outgoing::maxretries, remove_from_queue(), outgoing::retries, outgoing::retrytime, safe_append(), and outgoing::tech.
Referenced by scan_thread().
00395 { 00396 struct outgoing *o; 00397 FILE *f; 00398 o = malloc(sizeof(struct outgoing)); 00399 if (o) { 00400 init_outgoing(o); 00401 f = fopen(fn, "r+"); 00402 if (f) { 00403 if (!apply_outgoing(o, fn, f)) { 00404 #if 0 00405 printf("Filename: %s, Retries: %d, max: %d\n", fn, o->retries, o->maxretries); 00406 #endif 00407 fclose(f); 00408 if (o->retries <= o->maxretries) { 00409 now += o->retrytime; 00410 if (o->callingpid && (o->callingpid == ast_mainpid)) { 00411 safe_append(o, time(NULL), "DelayedRetry"); 00412 ast_log(LOG_DEBUG, "Delaying retry since we're currently running '%s'\n", o->fn); 00413 free_outgoing(o); 00414 } else { 00415 /* Increment retries */ 00416 o->retries++; 00417 /* If someone else was calling, they're presumably gone now 00418 so abort their retry and continue as we were... */ 00419 if (o->callingpid) 00420 safe_append(o, time(NULL), "AbortRetry"); 00421 00422 safe_append(o, now, "StartRetry"); 00423 launch_service(o); 00424 } 00425 return now; 00426 } else { 00427 ast_log(LOG_EVENT, "Queued call to %s/%s expired without completion after %d attempt%s\n", o->tech, o->dest, o->retries - 1, ((o->retries - 1) != 1) ? "s" : ""); 00428 free_outgoing(o); 00429 remove_from_queue(o, "Expired"); 00430 return 0; 00431 } 00432 } else { 00433 free_outgoing(o); 00434 ast_log(LOG_WARNING, "Invalid file contents in %s, deleting\n", fn); 00435 fclose(f); 00436 remove_from_queue(o, "Failed"); 00437 } 00438 } else { 00439 free_outgoing(o); 00440 ast_log(LOG_WARNING, "Unable to open %s: %s, deleting\n", fn, strerror(errno)); 00441 remove_from_queue(o, "Failed"); 00442 } 00443 } else 00444 ast_log(LOG_WARNING, "Out of memory :(\n"); 00445 return -1; 00446 }
static void* scan_thread | ( | void * | unused | ) | [static] |
Definition at line 448 of file pbx_spool.c.
References ast_log(), errno, last, LOG_WARNING, and scan_service().
Referenced by load_module().
00449 { 00450 struct stat st; 00451 DIR *dir; 00452 struct dirent *de; 00453 char fn[256]; 00454 int res; 00455 time_t last = 0, next = 0, now; 00456 for(;;) { 00457 /* Wait a sec */ 00458 sleep(1); 00459 time(&now); 00460 if (!stat(qdir, &st)) { 00461 if ((st.st_mtime != last) || (next && (now > next))) { 00462 #if 0 00463 printf("atime: %ld, mtime: %ld, ctime: %ld\n", st.st_atime, st.st_mtime, st.st_ctime); 00464 printf("Ooh, something changed / timeout\n"); 00465 #endif 00466 next = 0; 00467 last = st.st_mtime; 00468 dir = opendir(qdir); 00469 if (dir) { 00470 while((de = readdir(dir))) { 00471 snprintf(fn, sizeof(fn), "%s/%s", qdir, de->d_name); 00472 if (!stat(fn, &st)) { 00473 if (S_ISREG(st.st_mode)) { 00474 if (st.st_mtime <= now) { 00475 res = scan_service(fn, now, st.st_atime); 00476 if (res > 0) { 00477 /* Update next service time */ 00478 if (!next || (res < next)) { 00479 next = res; 00480 } 00481 } else if (res) 00482 ast_log(LOG_WARNING, "Failed to scan service '%s'\n", fn); 00483 } else { 00484 /* Update "next" update if necessary */ 00485 if (!next || (st.st_mtime < next)) 00486 next = st.st_mtime; 00487 } 00488 } 00489 } else 00490 ast_log(LOG_WARNING, "Unable to stat %s: %s\n", fn, strerror(errno)); 00491 } 00492 closedir(dir); 00493 } else 00494 ast_log(LOG_WARNING, "Unable to open directory %s: %s\n", qdir, strerror(errno)); 00495 } 00496 } else 00497 ast_log(LOG_WARNING, "Unable to stat %s\n", qdir); 00498 } 00499 return NULL; 00500 }
static int unload_module | ( | void | ) | [static] |
char qdir[255] [static] |
Definition at line 66 of file pbx_spool.c.
char qdonedir[255] [static] |
Definition at line 67 of file pbx_spool.c.