extern char my_name[];
extern time_t daemon_start_time;
extern int num_jobs_run;
-#ifdef SMARTALLOC
-extern uint64_t sm_max_bytes;
-extern uint64_t sm_bytes;
-extern uint32_t sm_max_buffers;
-extern uint32_t sm_buffers;
-#endif
static void list_scheduled_jobs(UAContext *ua);
static void list_running_jobs(UAContext *ua);
bstrftime_nc(dt, sizeof(dt), daemon_start_time);
bsendmsg(ua, _("Daemon started %s, %d Job%s run since started.\n"),
dt, num_jobs_run, num_jobs_run == 1 ? "" : "s");
-#ifdef SMARTALLOC
if (debug_level > 0) {
char b1[35], b2[35], b3[35], b4[35];
bsendmsg(ua, _(" Heap: bytes=%s max_bytes=%s bufs=%s max_bufs=%s\n"),
edit_uint64_with_commas(sm_max_bytes, b2),
edit_uint64_with_commas(sm_buffers, b3),
edit_uint64_with_commas(sm_max_buffers, b4));
- }
-#endif
+ }
/*
* List scheduled Jobs
*/
extern char my_name[];
extern int num_jobs_run;
extern time_t daemon_start_time;
-#ifdef SMARTALLOC
-extern uint64_t sm_max_bytes;
-extern uint64_t sm_bytes;
-extern uint32_t sm_max_buffers;
-extern uint32_t sm_buffers;
-#endif
/* Forward referenced functions */
static void list_terminated_jobs(void sendit(const char *msg, int len, void *sarg), void *arg);
sendit(msg, len, arg);
}
#endif
-#ifdef SMARTALLOC
if (debug_level > 0) {
len = Mmsg(&msg, _(" Heap: bytes=%s max_bytes=%s bufs=%s max_bufs=%s\n"),
edit_uint64_with_commas(sm_bytes, b1),
edit_uint64_with_commas(sm_max_buffers, b4));
sendit(msg, len, arg);
}
-#endif
if (debug_level > 0) {
len = Mmsg(&msg, _(" Sizeof: off_t=%d size_t=%d\n"), sizeof(off_t),
sizeof(size_t));
#define Dmsg4(l,f,a1,a2,a3,a4)
+uint64_t sm_max_bytes = 0;
+uint64_t sm_bytes = 0;
+uint32_t sm_max_buffers = 0;
+uint32_t sm_buffers = 0;
#ifdef SMARTALLOC
&abqueue, &abqueue
};
-uint64_t sm_max_bytes = 0;
-uint64_t sm_bytes = 0;
-uint32_t sm_max_buffers = 0;
-uint32_t sm_buffers = 0;
static bool bufimode = false; /* Buffers not tracked when True */
*/
+extern uint64_t sm_max_bytes;
+extern uint64_t sm_bytes;
+extern uint32_t sm_max_buffers;
+extern uint32_t sm_buffers;
#ifdef SMARTALLOC
extern time_t daemon_start_time;
extern int num_jobs_run;
+
/* Static variables */
bstrftime_nc(dt, sizeof(dt), daemon_start_time);
bnet_fsend(user, _("Daemon started %s, %d Job%s run since started.\n"), dt, num_jobs_run,
num_jobs_run == 1 ? "" : "s");
+ if (debug_level > 0) {
+ char b1[35], b2[35], b3[35], b4[35];
+ bnet_fsend(user, _(" Heap: bytes=%s max_bytes=%s bufs=%s max_bufs=%s\n"),
+ edit_uint64_with_commas(sm_bytes, b1),
+ edit_uint64_with_commas(sm_max_bytes, b2),
+ edit_uint64_with_commas(sm_buffers, b3),
+ edit_uint64_with_commas(sm_max_buffers, b4));
+ }
/*
* List running jobs