~ubuntu-branches/ubuntu/saucy/suricata/saucy-updates

« back to all changes in this revision

Viewing changes to src/counters.c

  • Committer: Package Import Robot
  • Author(s): Pierre Chifflier
  • Date: 2012-12-14 00:02:51 UTC
  • mfrom: (1.1.18)
  • Revision ID: package-import@ubuntu.com-20121214000251-3326bvmr1x6ofsy5
Tags: 1.4-1
* Imported Upstream version 1.4
* Enable Jansson and LuaJIT support, and add libjansson-dev libluajit-5.1-dev
  to build-deps
* Add python to recommends, for the suricatasc script
* Create /var/run/suricata directory when starting daemon

Show diffs side-by-side

added added

removed removed

Lines of Context:
420
420
    }
421
421
 
422
422
    SCFree(sc_perf_op_ctx);
 
423
    sc_perf_op_ctx = NULL;
423
424
 
424
425
    return;
425
426
}
446
447
        SCLogWarning(SC_ERR_THREAD_INIT, "Unable to set thread name");
447
448
    }
448
449
 
 
450
    if (tv_local->thread_setup_flags != 0)
 
451
        TmThreadSetupOptions(tv_local);
 
452
 
449
453
    /* Set the threads capability */
450
454
    tv_local->cap_flags = 0;
451
455
 
452
456
    SCDropCaps(tv_local);
453
457
 
 
458
 
454
459
    if (sc_perf_op_ctx == NULL) {
455
460
        SCLogError(SC_ERR_PERF_STATS_NOT_INIT, "Perf Counter API not init"
456
461
                   "SCPerfInitCounterApi() has to be called first");
507
512
        SCLogWarning(SC_ERR_THREAD_INIT, "Unable to set thread name");
508
513
    }
509
514
 
 
515
    if (tv_local->thread_setup_flags != 0)
 
516
        TmThreadSetupOptions(tv_local);
 
517
 
510
518
    /* Set the threads capability */
511
519
    tv_local->cap_flags = 0;
512
520
 
1214
1222
                   "failed");
1215
1223
        exit(EXIT_FAILURE);
1216
1224
    }
 
1225
 
1217
1226
    if (TmThreadSpawn(tv_wakeup) != 0) {
1218
1227
        SCLogError(SC_ERR_THREAD_SPAWN, "TmThreadSpawn failed for "
1219
1228
                   "SCPerfWakeupThread");
1228
1237
                   "TmThreadCreateMgmtThread failed");
1229
1238
        exit(EXIT_FAILURE);
1230
1239
    }
 
1240
 
1231
1241
    if (TmThreadSpawn(tv_mgmt) != 0) {
1232
1242
        SCLogError(SC_ERR_THREAD_SPAWN, "TmThreadSpawn failed for "
1233
1243
                   "SCPerfWakeupThread");