summaryrefslogtreecommitdiff
path: root/source3/include
diff options
context:
space:
mode:
Diffstat (limited to 'source3/include')
-rw-r--r--source3/include/messages.h9
-rw-r--r--source3/include/profile.h9
-rw-r--r--source3/include/proto.h1
3 files changed, 13 insertions, 6 deletions
diff --git a/source3/include/messages.h b/source3/include/messages.h
index 4ddb82ee30..b5e4f62593 100644
--- a/source3/include/messages.h
+++ b/source3/include/messages.h
@@ -23,9 +23,12 @@
#define _MESSAGES_H_
/* general messages */
-#define MSG_DEBUG 1
-#define MSG_PING 2
-#define MSG_PONG 3
+#define MSG_DEBUG 1
+#define MSG_PING 2
+#define MSG_PONG 3
+#define MSG_PROFILE 4
+#define MSG_REQ_DEBUGLEVEL 5
+#define MSG_DEBUGLEVEL 6
/* nmbd messages */
#define MSG_FORCE_ELECTION 1001
diff --git a/source3/include/profile.h b/source3/include/profile.h
index d18f598021..c196a63c62 100644
--- a/source3/include/profile.h
+++ b/source3/include/profile.h
@@ -319,6 +319,7 @@ extern struct profile_struct *profile_p;
extern struct timeval profile_starttime;
extern struct timeval profile_endtime;
extern BOOL do_profile_flag;
+extern BOOL do_profile_times;
/* these are helper macros - do not call them directly in the code
* use the DO_PROFILE_* START_PROFILE and END_PROFILE ones
@@ -349,17 +350,19 @@ extern BOOL do_profile_flag;
}
#define START_PROFILE(x) \
if (do_profile_flag) { \
- GetTimeOfDay(&profile_starttime); \
+ if (do_profile_times) \
+ GetTimeOfDay(&profile_starttime); \
INC_PROFILE_COUNT(x##_count); \
}
#define START_PROFILE_BYTES(x,n) \
if (do_profile_flag) { \
- GetTimeOfDay(&profile_starttime); \
+ if (do_profile_times) \
+ GetTimeOfDay(&profile_starttime); \
INC_PROFILE_COUNT(x##_count); \
ADD_PROFILE_COUNT(x##_bytes,n); \
}
#define END_PROFILE(x) \
- if (do_profile_flag) { \
+ if (do_profile_times) { \
GetTimeOfDay(&profile_endtime); \
ADD_PROFILE_COUNT(x##_time,PROFILE_TIME); \
}
diff --git a/source3/include/proto.h b/source3/include/proto.h
index 6c87c429c0..b29e3aa788 100644
--- a/source3/include/proto.h
+++ b/source3/include/proto.h
@@ -1784,6 +1784,7 @@ BOOL print_queue_purge(struct current_user *user, int snum, int *errcode);
/*The following definitions come from profile/profile.c */
+void profile_message(int msg_type, pid_t src, void *buf, size_t len);
BOOL profile_setup(BOOL rdonly);
/*The following definitions come from rpc_client/cli_connect.c */