Repository: trafficserver Updated Branches: refs/heads/master 842a06ed8 -> aacc6b5f9
TS-2619: Changed TSRecordDump declaration from TSRecordType to int to accomodate bitmasks. Also changed TSRecordType enums to hexidecimal, as this is easier to read for bit arguments. Project: http://git-wip-us.apache.org/repos/asf/trafficserver/repo Commit: http://git-wip-us.apache.org/repos/asf/trafficserver/commit/87cd3131 Tree: http://git-wip-us.apache.org/repos/asf/trafficserver/tree/87cd3131 Diff: http://git-wip-us.apache.org/repos/asf/trafficserver/diff/87cd3131 Branch: refs/heads/master Commit: 87cd3131bef13d8ed0330a8e6e019f4e1da9fc1d Parents: 842a06e Author: Justin Laue <[email protected]> Authored: Tue May 13 16:37:01 2014 -0600 Committer: Phil Sorber <[email protected]> Committed: Tue May 13 16:39:45 2014 -0600 ---------------------------------------------------------------------- lib/records/I_RecDefs.h | 16 ++++++++-------- lib/ts/apidefs.h.in | 16 ++++++++-------- proxy/InkAPI.cc | 2 +- proxy/api/ts/ts.h | 2 +- 4 files changed, 18 insertions(+), 18 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/trafficserver/blob/87cd3131/lib/records/I_RecDefs.h ---------------------------------------------------------------------- diff --git a/lib/records/I_RecDefs.h b/lib/records/I_RecDefs.h index 232d95c..2edaf92 100644 --- a/lib/records/I_RecDefs.h +++ b/lib/records/I_RecDefs.h @@ -56,14 +56,14 @@ typedef int8_t RecByte; enum RecT { - RECT_NULL = 0, - RECT_CONFIG = 1, - RECT_PROCESS = 2, - RECT_NODE = 4, - RECT_CLUSTER = 8, - RECT_LOCAL = 16, - RECT_PLUGIN = 32, - RECT_ALL = 63 + RECT_NULL = 0x00, + RECT_CONFIG = 0x01, + RECT_PROCESS = 0x02, + RECT_NODE = 0x04, + RECT_CLUSTER = 0x08, + RECT_LOCAL = 0x10, + RECT_PLUGIN = 0x20, + RECT_ALL = 0x3F }; enum RecDataT http://git-wip-us.apache.org/repos/asf/trafficserver/blob/87cd3131/lib/ts/apidefs.h.in ---------------------------------------------------------------------- diff --git a/lib/ts/apidefs.h.in b/lib/ts/apidefs.h.in index e909821..eae2b4f 100644 --- a/lib/ts/apidefs.h.in +++ b/lib/ts/apidefs.h.in @@ -601,14 +601,14 @@ extern "C" /* The values of this enum must match enum RecT in I_RecDefs.h */ typedef enum { - TS_RECORDTYPE_NULL = 0, - TS_RECORDTYPE_CONFIG = 1, - TS_RECORDTYPE_PROCESS = 2, - TS_RECORDTYPE_NODE = 4, - TS_RECORDTYPE_CLUSTER = 8, - TS_RECORDTYPE_LOCAL = 16, - TS_RECORDTYPE_PLUGIN = 32, - TS_RECORDTYPE_ALL = 63 + TS_RECORDTYPE_NULL = 0x00, + TS_RECORDTYPE_CONFIG = 0x01, + TS_RECORDTYPE_PROCESS = 0x02, + TS_RECORDTYPE_NODE = 0x04, + TS_RECORDTYPE_CLUSTER = 0x08, + TS_RECORDTYPE_LOCAL = 0x10, + TS_RECORDTYPE_PLUGIN = 0x20, + TS_RECORDTYPE_ALL = 0x3F } TSRecordType; /* The values of this enum must match enum RecDataT in I_RecDefs.h */ http://git-wip-us.apache.org/repos/asf/trafficserver/blob/87cd3131/proxy/InkAPI.cc ---------------------------------------------------------------------- diff --git a/proxy/InkAPI.cc b/proxy/InkAPI.cc index ecaa2d2..59d2203 100644 --- a/proxy/InkAPI.cc +++ b/proxy/InkAPI.cc @@ -7494,7 +7494,7 @@ TSAIOThreadNumSet(int thread_num) } void -TSRecordDump(TSRecordType rec_type, TSRecordDumpCb callback, void *edata) +TSRecordDump(int rec_type, TSRecordDumpCb callback, void *edata) { RecDumpRecords((RecT)rec_type, (RecDumpEntryCb)callback, edata); } http://git-wip-us.apache.org/repos/asf/trafficserver/blob/87cd3131/proxy/api/ts/ts.h ---------------------------------------------------------------------- diff --git a/proxy/api/ts/ts.h b/proxy/api/ts/ts.h index 5e88314..4e820aa 100644 --- a/proxy/api/ts/ts.h +++ b/proxy/api/ts/ts.h @@ -2005,7 +2005,7 @@ extern "C" typedef void (*TSRecordDumpCb) (TSRecordType rec_type, void* edata, int registered, const char* name, TSRecordDataType data_type, TSRecordData* datum); - tsapi void TSRecordDump(TSRecordType rec_type, TSRecordDumpCb callback, void* edata); + tsapi void TSRecordDump(int rec_type, TSRecordDumpCb callback, void* edata); /**
