From beroset:

remove C++ incompatibilities 
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8416

svn path=/trunk/; revision=48430
This commit is contained in:
Anders Broman 2013-03-19 22:03:00 +00:00
parent 7c56677cf9
commit ae747e4c4b
64 changed files with 180 additions and 178 deletions

View File

@ -37,7 +37,7 @@
static int proto_raw = -1;
static gint ett_raw = -1;
static const char zeroes[10];
static const char zeroes[10] = {0,0,0,0,0,0,0,0,0,0};
static dissector_handle_t ip_handle;
static dissector_handle_t ipv6_handle;

View File

@ -1418,7 +1418,7 @@ dissect_rdp_SendData(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) {
tree = proto_item_add_subtree(pi, ett_rdp_SendData);
conversation = find_or_create_conversation(pinfo);
rdp_info = conversation_get_proto_data(conversation, proto_rdp);
rdp_info = (rdp_conv_info_t *)conversation_get_proto_data(conversation, proto_rdp);
if (rdp_info &&
((rdp_info->licenseAgreed == 0) ||
@ -1627,10 +1627,10 @@ dissect_rdp_ClientData(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) {
conversation = find_or_create_conversation(pinfo);
rdp_info = conversation_get_proto_data(conversation, proto_rdp);
rdp_info = (rdp_conv_info_t *)conversation_get_proto_data(conversation, proto_rdp);
if (rdp_info == NULL) {
rdp_info = se_alloc0(sizeof(rdp_conv_info_t));
rdp_info = se_new0(rdp_conv_info_t);
rdp_info->staticChannelId = -1;
rdp_info->encryptionMethod = 0;
rdp_info->encryptionLevel = 0;
@ -1773,10 +1773,10 @@ dissect_rdp_ServerData(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) {
conversation = find_or_create_conversation(pinfo);
rdp_info = conversation_get_proto_data(conversation, proto_rdp);
rdp_info = (rdp_conv_info_t *)conversation_get_proto_data(conversation, proto_rdp);
if (rdp_info == NULL) {
rdp_info = se_alloc0(sizeof(rdp_conv_info_t));
rdp_info = se_new0(rdp_conv_info_t);
rdp_info->staticChannelId = -1;
rdp_info->encryptionMethod = 0;
rdp_info->encryptionLevel = 0;

View File

@ -267,13 +267,13 @@ void rdt_add_address(packet_info *pinfo,
conversation_set_dissector(p_conv, rdt_handle);
/* Check if the conversation has data associated with it. */
p_conv_data = conversation_get_proto_data(p_conv, proto_rdt);
p_conv_data = (struct _rdt_conversation_info *)conversation_get_proto_data(p_conv, proto_rdt);
/* If not, add a new data item. */
if (!p_conv_data)
{
/* Create conversation data */
p_conv_data = se_alloc(sizeof(struct _rdt_conversation_info));
p_conv_data = se_new(struct _rdt_conversation_info);
conversation_add_proto_data(p_conv, proto_rdt, p_conv_data);
}
@ -1233,7 +1233,7 @@ static void show_setup_info(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
struct _rdt_conversation_info *p_conv_data;
/* Use existing packet info if available */
p_conv_data = p_get_proto_data(pinfo->fd, proto_rdt);
p_conv_data = (struct _rdt_conversation_info *)p_get_proto_data(pinfo->fd, proto_rdt);
if (!p_conv_data)
{
@ -1245,12 +1245,12 @@ static void show_setup_info(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
{
/* Create space for conversation info */
struct _rdt_conversation_info *p_conv_packet_data;
p_conv_data = conversation_get_proto_data(p_conv, proto_rdt);
p_conv_data = (struct _rdt_conversation_info *)conversation_get_proto_data(p_conv, proto_rdt);
if (p_conv_data)
{
/* Save this conversation info into packet info */
p_conv_packet_data = se_alloc(sizeof(struct _rdt_conversation_info));
p_conv_packet_data = se_new(struct _rdt_conversation_info);
g_strlcpy(p_conv_packet_data->method, p_conv_data->method, MAX_RDT_SETUP_METHOD_SIZE);
p_conv_packet_data->frame_number = p_conv_data->frame_number;
p_conv_packet_data->feature_level = p_conv_data->feature_level;

View File

@ -387,7 +387,7 @@ static void rlogin_display(rlogin_hash_entry_t *hash_info,
static void
dissect_rlogin(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
{
struct tcpinfo *tcpinfo = pinfo->private_data;
struct tcpinfo *tcpinfo = (struct tcpinfo *)pinfo->private_data;
conversation_t *conversation;
rlogin_hash_entry_t *hash_info;
guint length;
@ -397,11 +397,11 @@ dissect_rlogin(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
conversation = find_or_create_conversation(pinfo);
/* Get or create data associated with this conversation */
hash_info = conversation_get_proto_data(conversation, proto_rlogin);
hash_info = (rlogin_hash_entry_t *)conversation_get_proto_data(conversation, proto_rlogin);
if (!hash_info)
{
/* Populate new data struct... */
hash_info = se_alloc(sizeof(rlogin_hash_entry_t));
hash_info = se_new(rlogin_hash_entry_t);
hash_info->state = NONE;
hash_info->info_framenum = 0; /* no frame has the number 0 */
hash_info->user_name[0] = '\0';

View File

@ -88,7 +88,7 @@ dissect_rmcp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data _U_
proto_tree *rmcp_tree = NULL, *field_tree;
proto_item *ti, *tf;
tvbuff_t *next_tvb;
guint8 class;
guint8 rmcp_class;
const gchar *class_str;
guint8 type;
guint len;
@ -99,13 +99,13 @@ dissect_rmcp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data _U_
*/
if (!tvb_bytes_exist(tvb, 3, 1))
return 0; /* class value byte not present */
class = tvb_get_guint8(tvb, 3);
rmcp_class = tvb_get_guint8(tvb, 3);
/* Get the normal/ack bit from the RMCP class */
type = (class & RMCP_TYPE_MASK) >> 7;
class &= RMCP_CLASS_MASK;
type = (rmcp_class & RMCP_TYPE_MASK) >> 7;
rmcp_class &= RMCP_CLASS_MASK;
class_str = match_strval(class, rmcp_class_vals);
class_str = match_strval(rmcp_class, rmcp_class_vals);
if (class_str == NULL)
return 0; /* unknown class value */
@ -138,7 +138,7 @@ dissect_rmcp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data _U_
next_tvb = tvb_new_subset_remaining(tvb, 4);
if (!dissector_try_uint(rmcp_dissector_table, class, next_tvb, pinfo,
if (!dissector_try_uint(rmcp_dissector_table, rmcp_class, next_tvb, pinfo,
tree)) {
len = call_dissector(data_handle, next_tvb, pinfo, tree);
if (len < tvb_length(next_tvb)) {

View File

@ -124,7 +124,7 @@ dissect_rmi(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
guint epid_len;
offset = 0;
rmitype = 0;
rmitype = (rmi_type)0;
/* Make entries in Protocol column and Info column on summary display */
col_set_str(pinfo->cinfo, COL_PROTOCOL, "RMI");

View File

@ -407,7 +407,7 @@ gboolean lct_dissector(struct _lct_ptr l, struct _fec_ptr f, tvbuff_t *tvb, prot
break;
}
tmp = ep_alloc(l.lct->toi_size);
tmp = (guint8 *)ep_alloc(l.lct->toi_size);
tvb_memcpy(tvb, tmp, *offset, l.lct->toi_size);
l.lct->toi_extended = tmp;

View File

@ -277,7 +277,7 @@ static void dissect_norm_data(struct _norm *norm, proto_tree *tree,
flags = tvb_get_guint8(tvb, offset);
flag_tree = proto_item_add_subtree(ti, ett.flags);
proto_tree_add_item(flag_tree, hf.flag.repair, tvb, offset, 1, ENC_BIG_ENDIAN);
proto_tree_add_item(flag_tree, hf.flag.explicit, tvb, offset, 1, ENC_BIG_ENDIAN);
proto_tree_add_item(flag_tree, hf.flag.norm_explicit, tvb, offset, 1, ENC_BIG_ENDIAN);
proto_tree_add_item(flag_tree, hf.flag.info, tvb, offset, 1, ENC_BIG_ENDIAN);
proto_tree_add_item(flag_tree, hf.flag.unreliable, tvb, offset, 1, ENC_BIG_ENDIAN);
proto_tree_add_item(flag_tree, hf.flag.file, tvb, offset, 1, ENC_BIG_ENDIAN);
@ -315,7 +315,7 @@ static void dissect_norm_info(struct _norm *norm, proto_tree *tree,
ti = proto_tree_add_item(tree, hf.flags, tvb, offset, 1, ENC_BIG_ENDIAN);
flag_tree = proto_item_add_subtree(ti, ett.flags);
proto_tree_add_item(flag_tree, hf.flag.repair, tvb, offset, 1, ENC_BIG_ENDIAN);
proto_tree_add_item(flag_tree, hf.flag.explicit, tvb, offset, 1, ENC_BIG_ENDIAN);
proto_tree_add_item(flag_tree, hf.flag.norm_explicit, tvb, offset, 1, ENC_BIG_ENDIAN);
proto_tree_add_item(flag_tree, hf.flag.info, tvb, offset, 1, ENC_BIG_ENDIAN);
proto_tree_add_item(flag_tree, hf.flag.unreliable, tvb, offset, 1, ENC_BIG_ENDIAN);
proto_tree_add_item(flag_tree, hf.flag.file, tvb, offset, 1, ENC_BIG_ENDIAN);
@ -702,7 +702,7 @@ void proto_register_norm(void)
{ "Flags", "norm.flags", FT_UINT8, BASE_HEX, NULL, 0x0, NULL, HFILL}},
{ &hf.flag.repair,
{ "Repair Flag", "norm.flag.repair", FT_BOOLEAN, 8, NULL, NORM_FLAG_REPAIR, NULL, HFILL }},
{ &hf.flag.explicit,
{ &hf.flag.norm_explicit,
{ "Explicit Flag", "norm.flag.explicit", FT_BOOLEAN, 8, NULL, NORM_FLAG_EXPLICIT, NULL, HFILL }},
{ &hf.flag.info,
{ "Info Flag", "norm.flag.info", FT_BOOLEAN, 8, NULL, NORM_FLAG_INFO, NULL, HFILL }},

View File

@ -143,7 +143,7 @@ struct _norm_hf
int nack_flags_object;
struct flaglist {
int repair;
int explicit;
int norm_explicit;
int info;
int unreliable;
int file;

View File

@ -914,7 +914,7 @@ dissect_rohc_feedback_data(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo,
/* Set mode at first pass? Do we need a new context for the following frames?
*
*/
rohc_cid_context->mode = (tvb_get_guint8(tvb,offset) & 0x30)>>4;
rohc_cid_context->mode = (enum rohc_mode)((tvb_get_guint8(tvb,offset) & 0x30)>>4);
proto_tree_add_item(rohc_feedback_tree, hf_rohc_acktype, tvb, offset, 1, ENC_BIG_ENDIAN);
proto_tree_add_item(rohc_feedback_tree, hf_rohc_mode, tvb, offset, 1, ENC_BIG_ENDIAN);
proto_tree_add_item(rohc_feedback_tree, hf_rohc_sn, tvb, offset, 2, ENC_BIG_ENDIAN);
@ -1535,7 +1535,7 @@ dissect_rohc_ir_rtp_profile_dynamic(tvbuff_t *tvb, packet_info *pinfo, proto_tre
return offset;
}
proto_tree_add_item(dynamic_rtp_tree, hf_rohc_rtp_x, tvb, offset, 1, ENC_BIG_ENDIAN);
rohc_cid_context->mode = (tvb_get_guint8(tvb,offset) & 0x0c)>>2;
rohc_cid_context->mode = (enum rohc_mode)((tvb_get_guint8(tvb,offset) & 0x0c)>>2);
proto_tree_add_item(dynamic_rtp_tree, hf_rohc_rtp_mode, tvb, offset, 1, ENC_BIG_ENDIAN);
proto_tree_add_item(dynamic_rtp_tree, hf_rohc_rtp_tis, tvb, offset, 1, ENC_BIG_ENDIAN);
proto_tree_add_item(dynamic_rtp_tree, hf_rohc_rtp_tss, tvb, offset, 1, ENC_BIG_ENDIAN);
@ -1848,7 +1848,7 @@ dissect_rohc_ir_packet(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo,
rohc_cid_context->prev_ir_frame_number = tmp_prev_ir_frame_number;
rohc_cid_context->ir_frame_number = pinfo->fd->num;
rohc_cid_context->rohc_ip_version = tmp_prev_rohc_ip_version;
rohc_cid_context->mode = tmp_prev_mode;
rohc_cid_context->mode = (enum rohc_mode)tmp_prev_mode;
rohc_cid_context->rnd = tmp_prev_rnd;
rohc_cid_context->udp_checksum_present = tmp_prev_udp_checksum_present;
rohc_cid_context->large_cid_present = p_rohc_info->large_cid_present;
@ -1970,7 +1970,7 @@ dissect_rohc_ir_dyn_packet(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo,
rohc_cid_context->prev_ir_frame_number = tmp_prev_ir_frame_number;
rohc_cid_context->ir_frame_number = pinfo->fd->num;
rohc_cid_context->rohc_ip_version = tmp_prev_rohc_ip_version;
rohc_cid_context->mode = tmp_prev_mode;
rohc_cid_context->mode = (enum rohc_mode)tmp_prev_mode;
rohc_cid_context->rnd = tmp_prev_rnd;
rohc_cid_context->udp_checksum_present = tmp_prev_udp_checksum_present;
rohc_cid_context->large_cid_present = p_rohc_info->large_cid_present;
@ -2045,7 +2045,7 @@ dissect_rohc(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
g_rohc_info.last_created_item = NULL;
p_rohc_info = &g_rohc_info;
}else{
p_rohc_info = pinfo->private_data;
p_rohc_info = (rohc_info *)pinfo->private_data;
memset(&g_rohc_info, 0, sizeof(rohc_info));
}
@ -2274,7 +2274,7 @@ start_over:
gint len;
get_self_describing_var_len_val(tvb, rohc_tree, offset+1, hf_rohc_large_cid, &val_len);
len = tvb_length_remaining(tvb, offset) - val_len;
data = ep_alloc(len);
data = (guint8 *)ep_alloc(len);
tvb_memcpy(tvb, data, offset, 1);
tvb_memcpy(tvb, &data[1], offset+1+val_len, len-1);
next_tvb = tvb_new_child_real_data(tvb, data, len, len);

View File

@ -121,9 +121,9 @@ dissect_rsh(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
/* Retrieve information from conversation
* or add it if it isn't there yet
*/
hash_info = conversation_get_proto_data(conversation, proto_rsh);
hash_info = (rsh_hash_entry_t *)conversation_get_proto_data(conversation, proto_rsh);
if(!hash_info){
hash_info = se_alloc(sizeof(rsh_hash_entry_t));
hash_info = se_new(rsh_hash_entry_t);
hash_info->first_packet_number = pinfo->fd->num;
hash_info->second_packet_number = 0;

View File

@ -6661,7 +6661,7 @@ dissect_rsvp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
/* If not, insert the new request key into the hash table */
if (!request_val) {
new_request_key = se_memdup(&request_key, sizeof(struct rsvp_request_key));
new_request_key = (struct rsvp_request_key *)se_memdup(&request_key, sizeof(struct rsvp_request_key));
request_val = se_new(struct rsvp_request_val);
request_val->value = conversation->index;

View File

@ -102,10 +102,10 @@ dissect_rsync_encap(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree,
conversation = find_or_create_conversation(pinfo);
conversation_data = conversation_get_proto_data(conversation, proto_rsync);
conversation_data = (struct rsync_conversation_data *)conversation_get_proto_data(conversation, proto_rsync);
if (conversation_data == NULL) {
conversation_data = se_alloc(sizeof(struct rsync_conversation_data));
conversation_data = se_new(struct rsync_conversation_data);
conversation_data->state = RSYNC_INIT;
conversation_add_proto_data(conversation, proto_rsync, conversation_data);
}
@ -116,10 +116,10 @@ dissect_rsync_encap(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree,
rsync_tree = proto_item_add_subtree(ti, ett_rsync);
rsync_frame_data_p = p_get_proto_data(pinfo->fd, proto_rsync);
rsync_frame_data_p = (struct rsync_frame_data *)p_get_proto_data(pinfo->fd, proto_rsync);
if (!rsync_frame_data_p) {
/* then we haven't seen this frame before */
rsync_frame_data_p = se_alloc(sizeof(struct rsync_frame_data));
rsync_frame_data_p = se_new(struct rsync_frame_data);
rsync_frame_data_p->state = conversation_data->state;
p_add_proto_data(pinfo->fd, proto_rsync, rsync_frame_data_p);
}

View File

@ -1330,7 +1330,7 @@ static gint rtps_util_add_typecode(proto_tree *tree,
*/
/* Calc indent string */
indent_string = ep_alloc((indent_level*2)+1);
indent_string = (char *)ep_alloc((indent_level*2)+1);
memset(indent_string, ' ', indent_level*2);
indent_string[indent_level*2] = '\0';

View File

@ -1226,7 +1226,7 @@ static gint rtps_util_add_typecode(proto_tree *tree,
*/
/* Calc indent string */
indent_string = ep_alloc((indent_level*2)+1);
indent_string = (char *)ep_alloc((indent_level*2)+1);
memset(indent_string, ' ', indent_level*2);
indent_string[indent_level*2] = '\0';

View File

@ -181,7 +181,7 @@ rtsp_stats_tree_init(stats_tree* st)
static int
rtsp_stats_tree_packet(stats_tree* st, packet_info* pinfo _U_, epan_dissect_t* edt _U_, const void* p)
{
const rtsp_info_value_t *v = p;
const rtsp_info_value_t *v = (const rtsp_info_value_t *)p;
guint i = v->response_code;
int resp_grp;
const gchar *resp_str;
@ -392,7 +392,7 @@ dissect_rtspinterleaved(tvbuff_t *tvb, int offset, packet_info *pinfo,
pinfo->srcport, pinfo->destport, 0);
if (conv &&
(data = conversation_get_proto_data(conv, proto_rtsp)) &&
(data = (rtsp_conversation_data_t *)conversation_get_proto_data(conv, proto_rtsp)) &&
/* Add the following condition if it is not always true.
rf_chan < RTSP_MAX_INTERLEAVED &&
*/
@ -590,12 +590,12 @@ rtsp_create_conversation(packet_info *pinfo, const guchar *line_begin,
conv = find_or_create_conversation(pinfo);
/* Look for previous data */
data = conversation_get_proto_data(conv, proto_rtsp);
data = (rtsp_conversation_data_t *)conversation_get_proto_data(conv, proto_rtsp);
/* Create new data if necessary */
if (!data)
{
data = se_alloc0(sizeof(rtsp_conversation_data_t));
data = se_new0(rtsp_conversation_data_t);
conversation_add_proto_data(conv, proto_rtsp, data);
}
@ -718,7 +718,7 @@ dissect_rtspmessage(tvbuff_t *tvb, int offset, packet_info *pinfo,
gchar *session_id = NULL;
voip_packet_info_t *stat_info = NULL;
rtsp_stat_info = ep_alloc(sizeof(rtsp_info_value_t));
rtsp_stat_info = ep_new(rtsp_info_value_t);
rtsp_stat_info->framenum = pinfo->fd->num;
rtsp_stat_info->response_code = 0;
rtsp_stat_info->request_method = NULL;
@ -1146,7 +1146,7 @@ dissect_rtspmessage(tvbuff_t *tvb, int offset, packet_info *pinfo,
}
if (session_id) {
stat_info = ep_alloc0(sizeof(voip_packet_info_t));
stat_info = ep_new0(voip_packet_info_t);
stat_info->protocol_name = ep_strdup("RTSP");
stat_info->call_id = session_id;
stat_info->frame_label = frame_label;

View File

@ -529,7 +529,7 @@ dissect_sametime_content(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
col_append_str(pinfo->cinfo, COL_INFO, " ");
/* message type statistic */
sinfo = ep_alloc(sizeof(struct SametimeTap ));
sinfo = ep_new(struct SametimeTap);
sinfo->message_type = message_type;
sinfo->send_type = -1;
sinfo->user_status = -1;

View File

@ -708,10 +708,10 @@ dissect_sbus(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data _U_
sbus_attribut = tvb_get_guint8(tvb,8);
if ( !request_val && sbus_attribut == 0 ) {/* request telegram */
new_request_key = se_alloc(sizeof(sbus_request_key));
new_request_key = se_new(sbus_request_key);
*new_request_key = request_key;
request_val = se_alloc(sizeof(sbus_request_val));
request_val = se_new(sbus_request_val);
request_val->cmd_code=tvb_get_guint8(tvb,10);
request_val->retry_count=0;
request_val->req_frame = pinfo->fd->num; /*store actual frame nr.*/

View File

@ -1436,7 +1436,7 @@ get_sccp_assoc(packet_info *pinfo, guint offset, guint32 src_lr, guint32 dst_lr,
if (assoc && trace_sccp) {
if ( ! PINFO_FD_VISITED(pinfo)) {
sccp_msg_info_t *msg = se_alloc0(sizeof(sccp_msg_info_t));
sccp_msg_info_t *msg = se_new0(sccp_msg_info_t);
msg->framenum = framenum;
msg->offset = offset;
msg->data.co.next = NULL;
@ -3337,7 +3337,7 @@ dissect_sccp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
*/
decode_mtp3_standard = mtp3_addr_p->type;
} else {
decode_mtp3_standard = mtp3_standard;
decode_mtp3_standard = (Standard_Type)mtp3_standard;
}
/* Make entry in the Protocol column on summary display */
@ -4001,7 +4001,7 @@ proto_register_sccp(void)
uat_t *users_uat = uat_new("SCCP Users Table", sizeof(sccp_user_t),
"sccp_users", TRUE, (void*) &sccp_users,
"sccp_users", TRUE, (void**) &sccp_users,
&num_sccp_users, UAT_AFFECTS_DISSECTION,
"ChSccpUsers", sccp_users_copy_cb,
sccp_users_update_cb, sccp_users_free_cb,

View File

@ -4474,7 +4474,7 @@ dissect_scsi_rsp(tvbuff_t *tvb, packet_info *pinfo,
cmdset_t *csdata;
scsi_task_data_t *cdata;
cdata = ep_alloc(sizeof(scsi_task_data_t));
cdata = ep_new(scsi_task_data_t);
cdata->itl = itl;
cdata->itlq = itlq;
cdata->type = SCSI_PDU_TYPE_RSP;
@ -4537,7 +4537,7 @@ dissect_scsi_snsinfo(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree,
const char *old_proto;
scsi_task_data_t *cdata;
cdata = ep_alloc(sizeof(scsi_task_data_t));
cdata = ep_new(scsi_task_data_t);
cdata->itl = itl;
cdata->itlq = itlq;
cdata->type = SCSI_PDU_TYPE_SNS;
@ -4886,7 +4886,7 @@ dissect_scsi_cdb(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree,
col_set_fence(pinfo->cinfo, COL_INFO);
}
cdata = ep_alloc(sizeof(scsi_task_data_t));
cdata = ep_new(scsi_task_data_t);
cdata->itl = itl;
cdata->itlq = itlq;
cdata->type = SCSI_PDU_TYPE_CDB;
@ -4967,7 +4967,7 @@ dissect_scsi_payload(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree,
}
payload_len = tvb_length(tvb);
cdata = ep_alloc(sizeof(scsi_task_data_t));
cdata = ep_new(scsi_task_data_t);
cdata->itl = itl;
cdata->itlq = itlq;
cdata->type = SCSI_PDU_TYPE_CDB;
@ -5169,7 +5169,7 @@ get_cmdset_data(itlq_nexus_t *itlq, itl_nexus_t *itl)
cmdset = scsi_def_devtype;
}
csdata = ep_alloc(sizeof(cmdset_t));
csdata = ep_new(cmdset_t);
switch(cmdset&SCSI_CMDSET_MASK) {
case SCSI_DEV_SBC:

View File

@ -1090,10 +1090,10 @@ dissect_spdu(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree,
has_user_information = TRUE;
break;
case SES_MAJOR_SYNC_POINT:
pres_ctx_id = p_get_proto_data (pinfo->fd, proto_ses);
pres_ctx_id = (guint32 *)p_get_proto_data (pinfo->fd, proto_ses);
if (ses_rtse_reassemble != 0 && !pres_ctx_id) {
/* First time visited - save pres_ctx_id */
pres_ctx_id = se_alloc (sizeof (guint32));
pres_ctx_id = se_new(guint32);
*pres_ctx_id = ses_pres_ctx_id;
p_add_proto_data (pinfo->fd, proto_ses, pres_ctx_id);
}

View File

@ -417,7 +417,7 @@ try_again:
sigcomp_tree = proto_item_add_subtree(ti, ett_sigcomp);
i=0;
end_off_message = FALSE;
buff = g_malloc(length-offset);
buff = (guint8 *)g_malloc(length-offset);
if (udvm_print_detail_level>2)
proto_tree_add_text(sigcomp_tree, tvb, offset, -1,"Starting to remove escape digits");
while ((offset < length) && (end_off_message == FALSE)){
@ -714,7 +714,7 @@ dissect_sigcomp_common(tvbuff_t *tvb, packet_info *pinfo, proto_tree *sigcomp_tr
/*
* Note: The allocated buffer must be zeroed or some strange effects might occur.
*/
buff = g_malloc0(UDVM_MEMORY_SIZE);
buff = (guint8 *)g_malloc0(UDVM_MEMORY_SIZE);
p_id_start = 0;

View File

@ -2171,7 +2171,7 @@ dissect_sip_common(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tr
}
/* Initialise stat info for passing to tap */
stat_info = ep_alloc0(sizeof(sip_info_value_t));
stat_info = ep_new0(sip_info_value_t);
col_set_str(pinfo->cinfo, COL_PROTOCOL, "SIP");
@ -3648,8 +3648,8 @@ guint sip_is_packet_resend(packet_info *pinfo,
/* Need to create a new table entry */
/* Allocate a new key and value */
p_key = se_alloc(sizeof(sip_hash_key));
p_val = se_alloc(sizeof(sip_hash_value));
p_key = se_new(sip_hash_key);
p_val = se_new(sip_hash_value);
/* Fill in key and value details */
g_snprintf(p_key->call_id, MAX_CALL_ID_SIZE, "%s", call_id);
@ -3740,7 +3740,7 @@ guint sip_is_packet_resend(packet_info *pinfo,
sip_frame_result = (sip_frame_result_value *)p_get_proto_data(pinfo->fd, proto_sip);
if (sip_frame_result == NULL)
{
sip_frame_result = se_alloc0(sizeof(sip_frame_result_value));
sip_frame_result = se_new0(sip_frame_result_value);
}
/* Store return value with this packet */
@ -3844,7 +3844,7 @@ guint sip_find_request(packet_info *pinfo,
if (sip_frame_result == NULL)
{
/* Allocate and set all values to zero */
sip_frame_result = se_alloc0(sizeof(sip_frame_result_value));
sip_frame_result = se_new0(sip_frame_result_value);
}
sip_frame_result->response_request_frame_num = result;
@ -3964,7 +3964,7 @@ guint sip_find_invite(packet_info *pinfo,
if (sip_frame_result == NULL)
{
/* Allocate and set all values to zero */
sip_frame_result = se_alloc0(sizeof(sip_frame_result_value));
sip_frame_result = se_new0(sip_frame_result_value);
}
sip_frame_result->response_request_frame_num = result;

View File

@ -173,10 +173,10 @@ dissect_skype_udp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
conversation = find_or_create_conversation(pinfo);
/* if conversation found get the data pointer that you stored */
skype_udp_info = conversation_get_proto_data(conversation, proto_skype);
skype_udp_info = (skype_udp_conv_info_t *)conversation_get_proto_data(conversation, proto_skype);
if (!skype_udp_info) {
/* new conversation create local data structure */
skype_udp_info = se_alloc(sizeof(skype_udp_conv_info_t));
skype_udp_info = se_new(skype_udp_conv_info_t);
skype_udp_info->global_src_ip = 0;
skype_udp_info->global_dst_ip = 0;
conversation_add_proto_data(conversation, proto_skype,

View File

@ -2721,7 +2721,7 @@ dissect_smpp_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
} /* if (tree || (command_id == 4)) */
/* Queue packet for Tap */
tap_rec = ep_alloc0(sizeof(smpp_tap_rec_t));
tap_rec = ep_new0(smpp_tap_rec_t);
tap_rec->command_id = command_id;
tap_rec->command_status = command_status;
tap_queue_packet(smpp_tap, pinfo, tap_rec);

View File

@ -331,12 +331,12 @@ dissect_smtp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
/*
* Is there a request structure attached to this conversation?
*/
session_state = conversation_get_proto_data(conversation, proto_smtp);
session_state = (struct smtp_session_state *)conversation_get_proto_data(conversation, proto_smtp);
if (!session_state) {
/*
* No - create one and attach it.
*/
session_state = wmem_alloc(wmem_file_scope(), sizeof(struct smtp_session_state));
session_state = (struct smtp_session_state *)wmem_alloc(wmem_file_scope(), sizeof(struct smtp_session_state));
session_state->smtp_state = SMTP_STATE_READING_CMDS;
session_state->auth_state = SMTP_AUTH_STATE_NONE;
session_state->first_auth_frame = 0;
@ -382,7 +382,7 @@ dissect_smtp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
/*
* Is there any data attached to this frame?
*/
spd_frame_data = p_get_proto_data(pinfo->fd, proto_smtp);
spd_frame_data = (struct smtp_proto_data *)p_get_proto_data(pinfo->fd, proto_smtp);
if (!spd_frame_data) {
@ -394,7 +394,7 @@ dissect_smtp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
/*
* Create a frame data structure and attach it to the packet.
*/
spd_frame_data = wmem_alloc0(wmem_file_scope(), sizeof(struct smtp_proto_data));
spd_frame_data = (struct smtp_proto_data *)wmem_alloc0(wmem_file_scope(), sizeof(struct smtp_proto_data));
spd_frame_data->conversation_id = conversation->index;
spd_frame_data->more_frags = TRUE;

View File

@ -386,7 +386,7 @@ socks_udp_dissector(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) {
DISSECTOR_ASSERT( conversation); /* should always find a conversation */
hash_info = conversation_get_proto_data(conversation, proto_socks);
hash_info = (socks_hash_entry_t *)conversation_get_proto_data(conversation, proto_socks);
col_set_str(pinfo->cinfo, COL_PROTOCOL, "Socks");
@ -980,7 +980,7 @@ static void call_next_dissector(tvbuff_t *tvb, int offset, packet_info *pinfo,
/* the payload, and restore the pinfo port after that is done. */
guint32 *ptr;
struct tcpinfo *tcpinfo = pinfo->private_data;
struct tcpinfo *tcpinfo = (struct tcpinfo *)pinfo->private_data;
guint16 save_can_desegment;
struct tcp_analysis *tcpd=NULL;
@ -1040,9 +1040,9 @@ dissect_socks(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) {
}
conversation = find_or_create_conversation(pinfo);
hash_info = conversation_get_proto_data(conversation,proto_socks);
hash_info = (socks_hash_entry_t *)conversation_get_proto_data(conversation,proto_socks);
if ( !hash_info){
hash_info = se_alloc(sizeof(socks_hash_entry_t));
hash_info = se_new(socks_hash_entry_t);
hash_info->start_done_row = G_MAXINT;
hash_info->state = None;
hash_info->port = 0;

View File

@ -3134,7 +3134,7 @@ dissect_spice(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data _U
spice_info = (spice_conversation_t*)conversation_get_proto_data(conversation, proto_spice);
if (!spice_info) {
spice_info = se_alloc0(sizeof(spice_conversation_t));
spice_info = se_new0(spice_conversation_t);
spice_info->destport = pinfo->destport;
spice_info->channel_type = SPICE_CHANNEL_NONE;
spice_info->next_state = SPICE_LINK_CLIENT;
@ -3147,9 +3147,9 @@ dissect_spice(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data _U
conversation_set_dissector(conversation, spice_handle);
}
per_packet_info = p_get_proto_data(pinfo->fd, proto_spice);
per_packet_info = (spice_packet_t *)p_get_proto_data(pinfo->fd, proto_spice);
if (!per_packet_info) {
per_packet_info = se_alloc(sizeof(spice_packet_t));
per_packet_info = se_new(spice_packet_t);
per_packet_info->state = spice_info->next_state;
p_add_proto_data(pinfo->fd, proto_spice, per_packet_info);
}

View File

@ -807,14 +807,14 @@ void sprt_add_address(packet_info *pinfo,
/*
* Check if the conversation has data associated with it.
*/
p_conv_data = conversation_get_proto_data(p_conv, proto_sprt);
p_conv_data = (struct _sprt_conversation_info *)conversation_get_proto_data(p_conv, proto_sprt);
/*
* If not, add a new data item.
*/
if (!p_conv_data) {
/* Create conversation data */
p_conv_data = se_alloc(sizeof(struct _sprt_conversation_info));
p_conv_data = se_new(struct _sprt_conversation_info);
p_conv_data->stream_started = FALSE;
p_conv_data->seqnum[0] = 0;
p_conv_data->seqnum[1] = 0;

View File

@ -456,7 +456,7 @@ unicode_to_bytes(tvbuff_t *tvb, int offset, int length, gboolean endianness)
return "";
if (endianness) {
byte_array = ep_alloc(length*2 + 1);
byte_array = (guint8 *)ep_alloc(length*2 + 1);
for (i = length; i > 0; i--) {
c_char = ascii_text[i];
if (c_char != 0) {
@ -475,7 +475,7 @@ unicode_to_bytes(tvbuff_t *tvb, int offset, int length, gboolean endianness)
}
else
{
byte_array = ep_alloc(length + 1);
byte_array = (guint8 *)ep_alloc(length + 1);
for (i = 0; i < length; i++) {
c_char = ascii_text[i];
if (c_char != 0) {

View File

@ -339,7 +339,7 @@ static void dissect_sscop(tvbuff_t* tvb, packet_info* pinfo,proto_tree* tree)
dissector_handle_t subdissector;
/* Look for packet info for subdissector information */
p_sscop_info = p_get_proto_data(pinfo->fd, proto_sscop);
p_sscop_info = (struct _sscop_payload_info *)p_get_proto_data(pinfo->fd, proto_sscop);
if ( p_sscop_info
&& ( subdissector = p_sscop_info->subdissector )

View File

@ -476,18 +476,18 @@ dissect_stun_message(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, gboole
/*
* Do we already have a state structure for this conv
*/
stun_info = conversation_get_proto_data(conversation, proto_stun);
stun_info = (stun_conv_info_t *)conversation_get_proto_data(conversation, proto_stun);
if (!stun_info) {
/* No. Attach that information to the conversation, and add
* it to the list of information structures.
*/
stun_info = se_alloc(sizeof(stun_conv_info_t));
stun_info = se_new(stun_conv_info_t);
stun_info->transaction_pdus=se_tree_create_non_persistent(EMEM_TREE_TYPE_RED_BLACK, "stun_transaction_pdus");
conversation_add_proto_data(conversation, proto_stun, stun_info);
}
if (!pinfo->fd->flags.visited) {
if ((stun_trans =
if ((stun_trans = (stun_transaction_t *)
se_tree_lookup32_array(stun_info->transaction_pdus,
transaction_id_key)) == NULL) {
@ -496,7 +496,7 @@ dissect_stun_message(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, gboole
transaction_id_key[1].length = 0;
transaction_id_key[1].key = NULL;
stun_trans=se_alloc(sizeof(stun_transaction_t));
stun_trans=se_new(stun_transaction_t);
stun_trans->req_frame=0;
stun_trans->rep_frame=0;
stun_trans->req_time=pinfo->fd->abs_ts;
@ -519,13 +519,13 @@ dissect_stun_message(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, gboole
}
} else {
stun_trans=se_tree_lookup32_array(stun_info->transaction_pdus,
stun_trans=(stun_transaction_t *)se_tree_lookup32_array(stun_info->transaction_pdus,
transaction_id_key);
}
if (!stun_trans) {
/* create a "fake" pana_trans structure */
stun_trans=ep_alloc(sizeof(stun_transaction_t));
stun_trans=ep_new(stun_transaction_t);
stun_trans->req_frame=0;
stun_trans->rep_frame=0;
stun_trans->req_time=pinfo->fd->abs_ts;

View File

@ -126,12 +126,14 @@ typedef enum { integer, /* 16 bit signed integer */
floating_point /* single precision floating point */
} data_format;
typedef enum { rect, polar } phasor_notation;
typedef enum { rect, polar } phasor_notation_e;
typedef enum { V, A } unit_e;
/* holds the information required to dissect a single phasor */
typedef struct {
char name[CHNAM_LEN + 1];
enum { V, A } unit;
unit_e unit;
guint32 conv; /* conversation factor in 10^-5 scale */
} phasor_info;
@ -148,7 +150,7 @@ typedef struct {
data_format format_fr; /* data format of FREQ and DFREQ */
data_format format_ph; /* data format of PHASORS */
data_format format_an; /* data format of ANALOG */
phasor_notation phasor_notation; /* format of the phasors */
phasor_notation_e phasor_notation; /* format of the phasors */
guint fnom; /* nominal line frequency */
guint num_dg; /* number of digital status words */
GArray *phasors; /* array of phasor_infos */
@ -551,7 +553,7 @@ static void dissect_common(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
0);
if (conversation) {
config_frame *conf = conversation_get_proto_data(conversation, proto_synphasor);
config_frame *conf = (config_frame *)conversation_get_proto_data(conversation, proto_synphasor);
/* no problem if 'conf' is NULL, the DATA frame dissector checks this again */
p_add_proto_data(pinfo->fd, proto_synphasor, conf);
}
@ -792,7 +794,7 @@ static int dissect_data_frame(tvbuff_t *tvb,
/* search for configuration information to dissect the frame */
{
gboolean config_found = FALSE;
conf = p_get_proto_data(pinfo->fd, proto_synphasor);
conf = (config_frame *)p_get_proto_data(pinfo->fd, proto_synphasor);
if (conf) {
/* check if the size of the current frame is the
@ -891,7 +893,7 @@ static int dissect_command_frame(tvbuff_t *tvb,
static int dissect_single_phasor(tvbuff_t *tvb, int offset,
double* mag, double* phase, /* returns the resulting values here */
data_format format, /* information needed to... */
phasor_notation notation) /* ...dissect the phasor */
phasor_notation_e notation) /* ...dissect the phasor */
{
if (floating_point == format) {
if (polar == notation) {

View File

@ -488,7 +488,7 @@ t30_get_string_numbers(tvbuff_t *tvb, int offset, int len)
if (len != LENGTH_T30_NUM)
return NULL;
buf=ep_alloc(LENGTH_T30_NUM+1);
buf=(gchar *)ep_alloc(LENGTH_T30_NUM+1);
for (i=0; i<LENGTH_T30_NUM; i++)
buf[LENGTH_T30_NUM-i-1] = reverse_byte(tvb_get_guint8(tvb, offset+i));
@ -548,7 +548,7 @@ dissect_t30_facsimile_coded_data(tvbuff_t *tvb, int offset, packet_info *pinfo,
if (pinfo->private_data)
g_snprintf(((t38_packet_info*)pinfo->private_data)->desc, MAX_T38_DESC, "Frm num: %d", reverse_byte(octet));
t4_data = ep_alloc(len-1);
t4_data = (guint8 *)ep_alloc(len-1);
tvb_memcpy(tvb, t4_data, offset, len-1);
proto_tree_add_bytes(tree, hf_t30_t4_data, tvb, offset, len-1, t4_data);
}
@ -571,7 +571,7 @@ dissect_t30_non_standard_cap(tvbuff_t *tvb, int offset, packet_info *pinfo, int
proto_tree_add_uint(tree, hf_t30_fif_country_code, tvb, offset, 1, octet);
offset++;
non_standard_bytes = ep_alloc(len-1);
non_standard_bytes = (guint8 *)ep_alloc(len-1);
tvb_memcpy(tvb, non_standard_bytes, offset, len-1);
proto_tree_add_bytes(tree, hf_t30_fif_non_stand_bytes, tvb, offset, len-1, non_standard_bytes);
@ -624,7 +624,7 @@ dissect_t30_partial_page_request(tvbuff_t *tvb, int offset, packet_info *pinfo,
int frame_count = 0;
int frame;
#define BUF_SIZE (10*1 + 90*2 + 156*3 + 256*2 + 1) /* 0..9 + 10..99 + 100..255 + 256*', ' + \0 */
gchar *buf = ep_alloc(BUF_SIZE);
gchar *buf = (gchar *)ep_alloc(BUF_SIZE);
gchar *buf_top = buf;
if (len != 32) {

View File

@ -1182,7 +1182,7 @@ dissect_tds7_login(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
len *= 2;
val = (gchar*)tvb_get_ephemeral_string(tvb, offset2, len);
val2 = ep_alloc((len/2)+1);
val2 = (char *)ep_alloc((len/2)+1);
for(j = 0, k = 0; j < len; j += 2, k++) {
val[j] ^= 0xA5;
@ -1310,7 +1310,7 @@ dissect_tds_col_info_token(tvbuff_t *tvb, struct _netlib_data *nl_data, guint of
return FALSE;
}
nl_data->columns[col] = ep_alloc(sizeof(struct _tds_col));
nl_data->columns[col] = ep_new(struct _tds_col);
nl_data->columns[col]->name[0] ='\0';
@ -1368,7 +1368,7 @@ read_results_tds5(tvbuff_t *tvb, struct _netlib_data *nl_data, guint offset, gui
cur += 2;
for (i = 0; i < nl_data->num_cols; i++) {
nl_data->columns[i] = ep_alloc(sizeof(struct _tds_col));
nl_data->columns[i] = ep_new(struct _tds_col);
name_len = tvb_get_guint8(tvb,cur);
cur ++;
cur += name_len;

View File

@ -391,8 +391,8 @@ static void ts2_standard_dissect(tvbuff_t *tvb, packet_info *pinfo, proto_tree *
/* XXX: Following fragmentation stuff should be separate from the GUI stuff ?? */
/* Get our stored fragmentation data or create one! */
if ( ! ( frag = p_get_proto_data(pinfo->fd, proto_ts2) ) ) {
frag = se_alloc(sizeof(ts2_frag));
if ( ! ( frag = (ts2_frag *)p_get_proto_data(pinfo->fd, proto_ts2) ) ) {
frag = se_new(ts2_frag);
frag->frag_num=0;
}
@ -419,7 +419,7 @@ static void ts2_standard_dissect(tvbuff_t *tvb, packet_info *pinfo, proto_tree *
}
/* Get our stored fragmentation data */
frag = p_get_proto_data(pinfo->fd, proto_ts2);
frag = (ts2_frag *)p_get_proto_data(pinfo->fd, proto_ts2);
proto_tree_add_item(ts2_tree, hf_ts2_resend_count, tvb, 16, 2, ENC_LITTLE_ENDIAN);
proto_tree_add_item(ts2_tree, hf_ts2_fragmentnumber, tvb, 18, 2, ENC_LITTLE_ENDIAN);
@ -698,7 +698,7 @@ static ts2_conversation* ts2_get_conversation(packet_info *pinfo)
}
else
{
conversation_data = se_alloc(sizeof(*conversation_data));
conversation_data = se_new(ts2_conversation);
conversation_data->last_inorder_server_frame=0; /* sequence number should never be zero so we can use this as an initial number */
conversation_data->last_inorder_client_frame=0;
conversation_data->server_port=pinfo->srcport;
@ -825,7 +825,7 @@ static gboolean ts2_add_checked_crc32(proto_tree *tree, int hf_item, tvbuff_t *t
{
guint8 *zero;
guint32 ocrc32;
zero = ep_alloc0(4);
zero = (guint8 *)ep_alloc0(4);
ocrc32 = crc32_ccitt_tvb(tvb, offset);
ocrc32 = crc32_ccitt_seed(zero, 4, 0xffffffff-ocrc32);
ocrc32 = crc32_ccitt_tvb_offset_seed(tvb, offset+4, tvb_reported_length_remaining(tvb, offset+4), 0xffffffff-ocrc32);

View File

@ -64,7 +64,7 @@ dissect_telkonet(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
col_set_str(pinfo->cinfo, COL_PROTOCOL, "TELKONET");
col_clear(pinfo->cinfo, COL_INFO);
type = tvb_get_guint8(tvb, offset);
type = (telkonet_type_t)tvb_get_guint8(tvb, offset);
if (check_col(pinfo->cinfo, COL_INFO)) {
col_add_fstr(pinfo->cinfo, COL_INFO, "Telkonet type: %s",
val_to_str(type, telkonet_type_vals, "Unknown (0x%02x)"));

View File

@ -982,7 +982,7 @@ unescape_and_tvbuffify_telnet_option(packet_info *pinfo, tvbuff_t *tvb, int offs
return NULL;
spos=tvb_get_ptr(tvb, offset, len);
buf=g_malloc(len);
buf=(guint8 *)g_malloc(len);
dpos=buf;
skip=0;
l=len;

View File

@ -334,9 +334,9 @@ dissect_embeddedtftp_heur(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, v
conversation = find_or_create_conversation(pinfo);
tftp_info = conversation_get_proto_data(conversation, proto_tftp);
tftp_info = (tftp_conv_info_t *)conversation_get_proto_data(conversation, proto_tftp);
if (!tftp_info) {
tftp_info = se_alloc(sizeof(tftp_conv_info_t));
tftp_info = se_new(tftp_conv_info_t);
tftp_info->blocksize = 512; /* TFTP default block size */
tftp_info->source_file = NULL;
tftp_info->destination_file = NULL;
@ -406,9 +406,9 @@ dissect_tftp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
return;
}
}
tftp_info = conversation_get_proto_data(conversation, proto_tftp);
tftp_info = (tftp_conv_info_t *)conversation_get_proto_data(conversation, proto_tftp);
if (!tftp_info) {
tftp_info = se_alloc(sizeof(tftp_conv_info_t));
tftp_info = se_new(tftp_conv_info_t);
tftp_info->blocksize = 512; /* TFTP default block size */
tftp_info->source_file = NULL;
tftp_info->destination_file = NULL;

View File

@ -42,7 +42,7 @@ static int proto_time = -1;
static int hf_time_time = -1;
static gint ett_time = -1;
static gint time_display_type = ABSOLUTE_TIME_LOCAL;
static absolute_time_display_e time_display_type = ABSOLUTE_TIME_LOCAL;
/* This dissector works for TCP and UDP time packets */
#define TIME_PORT 37
@ -102,7 +102,7 @@ proto_register_time(void)
"display_time_type",
"Time Display",
"Time display type",
&time_display_type,
(gint *)&time_display_type,
time_display_types,
FALSE);

View File

@ -574,7 +574,7 @@ tipc_addr_to_str(guint tipc_address)
guint16 processor;
gchar *buff;
buff = ep_alloc(MAX_TIPC_ADDRESS_STR_LEN);
buff = (gchar *)ep_alloc(MAX_TIPC_ADDRESS_STR_LEN);
processor = tipc_address & 0x0fff;

View File

@ -5269,7 +5269,7 @@ dissect_tn3270(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
pinfo->destport, 0);
if (conversation != NULL) {
/* Do we already have a type and mechanism? */
tn3270_info = conversation_get_proto_data(conversation, proto_tn3270);
tn3270_info = (tn3270_conv_info_t *)conversation_get_proto_data(conversation, proto_tn3270);
}
if (tn3270_info == NULL)
@ -5317,12 +5317,12 @@ add_tn3270_conversation(packet_info *pinfo, int tn3270e, gint model)
/*
* Do we already have a type and mechanism?
*/
tn3270_info = conversation_get_proto_data(conversation, proto_tn3270);
tn3270_info = (tn3270_conv_info_t *)conversation_get_proto_data(conversation, proto_tn3270);
if (tn3270_info == NULL) {
/* No. Attach that information to the conversation, and add
* it to the list of information structures.
*/
tn3270_info = se_alloc(sizeof(tn3270_conv_info_t));
tn3270_info = se_new(tn3270_conv_info_t);
COPY_ADDRESS(&(tn3270_info->outbound_addr), &(pinfo->dst));
tn3270_info->outbound_port = pinfo->destport;
@ -5373,7 +5373,7 @@ find_tn3270_conversation(packet_info *pinfo)
pinfo->ptype, pinfo->srcport,
pinfo->destport, 0);
if (conversation != NULL) {
tn3270_info = conversation_get_proto_data(conversation, proto_tn3270);
tn3270_info = (tn3270_conv_info_t *)conversation_get_proto_data(conversation, proto_tn3270);
if (tn3270_info != NULL) {
/*
* Do we already have a type and mechanism?

View File

@ -5101,7 +5101,7 @@ dissect_tn5250(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
pinfo->destport, 0);
if (conversation != NULL) {
/* Do we already have a type and mechanism? */
tn5250_info = conversation_get_proto_data(conversation, proto_tn5250);
tn5250_info = (tn5250_conv_info_t *)conversation_get_proto_data(conversation, proto_tn5250);
}
if (!tn5250_info)
@ -5144,12 +5144,12 @@ add_tn5250_conversation(packet_info *pinfo, int tn5250e)
/*
* Do we already have a type and mechanism?
*/
tn5250_info = conversation_get_proto_data(conversation, proto_tn5250);
tn5250_info = (tn5250_conv_info_t *)conversation_get_proto_data(conversation, proto_tn5250);
if (tn5250_info == NULL) {
/* No. Attach that information to the conversation, and add
* it to the list of information structures.
*/
tn5250_info = se_alloc(sizeof(tn5250_conv_info_t));
tn5250_info = se_new(tn5250_conv_info_t);
SE_COPY_ADDRESS(&(tn5250_info->outbound_addr),&(pinfo->dst));
tn5250_info->outbound_port = pinfo->destport;
SE_COPY_ADDRESS(&(tn5250_info->inbound_addr),&(pinfo->src));
@ -5177,7 +5177,7 @@ find_tn5250_conversation(packet_info *pinfo)
pinfo->destport, 0);
if (conversation != NULL) {
tn5250_info = conversation_get_proto_data(conversation, proto_tn5250);
tn5250_info = (tn5250_conv_info_t *)conversation_get_proto_data(conversation, proto_tn5250);
if (tn5250_info != NULL) {
/*

View File

@ -512,11 +512,11 @@ dissect_tr(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
proto_tree_add_uint(bf_tree, hf_tr_fc_type, tr_tvb, 1, 1, trh->fc);
proto_tree_add_uint(bf_tree, hf_tr_fc_pcf, tr_tvb, 1, 1, trh->fc);
proto_tree_add_ether(tr_tree, hf_tr_dst, tr_tvb, 2, 6, trh->dst.data);
proto_tree_add_ether(tr_tree, hf_tr_src, tr_tvb, 8, 6, trh->src.data);
hidden_item = proto_tree_add_ether(tr_tree, hf_tr_addr, tr_tvb, 2, 6, trh->dst.data);
proto_tree_add_ether(tr_tree, hf_tr_dst, tr_tvb, 2, 6, (guint8 *)trh->dst.data);
proto_tree_add_ether(tr_tree, hf_tr_src, tr_tvb, 8, 6, (guint8 *)trh->src.data);
hidden_item = proto_tree_add_ether(tr_tree, hf_tr_addr, tr_tvb, 2, 6, (guint8 *)trh->dst.data);
PROTO_ITEM_SET_HIDDEN(hidden_item);
hidden_item = proto_tree_add_ether(tr_tree, hf_tr_addr, tr_tvb, 8, 6, trh->src.data);
hidden_item = proto_tree_add_ether(tr_tree, hf_tr_addr, tr_tvb, 8, 6, (guint8 *)trh->src.data);
PROTO_ITEM_SET_HIDDEN(hidden_item);
proto_tree_add_boolean(tr_tree, hf_tr_sr, tr_tvb, 8, 1, source_routed);
@ -598,7 +598,7 @@ add_ring_bridge_pairs(int rcf_len, tvbuff_t *tvb, proto_tree *tree)
char *buffer;
#define MAX_BUF_LEN 3 + (RIF_BYTES_TO_PROCESS / 2) * 6 + 1
buffer=ep_alloc(MAX_BUF_LEN);
buffer=(char *)ep_alloc(MAX_BUF_LEN);
/* Only process so many bytes of RIF, as per TR spec, and not overflow
* static buffer above */
unprocessed_rif = rcf_len - RIF_BYTES_TO_PROCESS;

View File

@ -1823,7 +1823,7 @@ dissect_ucp_common(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
OT = 10 * OT + (tvb_get_guint8(tvb, UCP_OT_OFFSET + 1) - '0');
/* Create Tap record */
tap_rec = ep_alloc0(sizeof(ucp_tap_rec_t));
tap_rec = ep_new0(ucp_tap_rec_t);
tap_rec->message_type = (O_R == 'O' ? 0 : 1);
tap_rec->operation = OT;

View File

@ -3762,7 +3762,7 @@ heur_dissect_fp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data
* with the corresponding generator polynomial: G(D) = D7+D6+D2+1. See subclause 7.2.
*/
length = tvb_length(tvb);
buf = ep_tvb_memdup(tvb, 0, length);
buf = (unsigned char *)ep_tvb_memdup(tvb, 0, length);
buf[0] = 01;
calc_crc = crc7update(calc_crc, buf, length);
@ -3884,7 +3884,7 @@ fp_set_per_packet_inf_from_conv(umts_fp_conversation_info_t *p_conv_data,
if(fpi->hsdsch_entity == hs /*&& !rlc_is_ciphered(pinfo)*/){
for(i=0; i<MAX_NUM_HSDHSCH_MACDFLOW; i++){
/*Figure out if this channel is multiplexed (signaled from RRC)*/
if((cur_val=g_tree_lookup(hsdsch_muxed_flows, GINT_TO_POINTER((gint)p_conv_data->hrnti))) != NULL){
if((cur_val=(gint *)g_tree_lookup(hsdsch_muxed_flows, GINT_TO_POINTER((gint)p_conv_data->hrnti))) != NULL){
j = 1 << i;
fpi->hsdhsch_macfdlow_is_mux[i] = j & *cur_val;
}else{

View File

@ -1126,7 +1126,7 @@ dissect_usb_device_descriptor(packet_info *pinfo, proto_tree *parent_tree,
hfi = proto_registrar_get_nth(hf_usb_idProduct);
field_description_length = (gint)strlen(hfi->name) + 14;
field_description = ep_alloc(field_description_length);
field_description = (guint8 *)ep_alloc(field_description_length);
g_strlcpy(field_description, hfi->name, field_description_length);
g_strlcat(field_description, ": %s (0x%04x)", field_description_length);

View File

@ -151,8 +151,8 @@ static void dissect_user(tvbuff_t* tvb, packet_info* pinfo, proto_tree* tree) {
static void* user_copy_cb(void* dest, const void* orig, size_t len _U_)
{
const user_encap_t *o = orig;
user_encap_t *d = dest;
const user_encap_t *o = (const user_encap_t *)orig;
user_encap_t *d = (user_encap_t *)dest;
d->payload_proto_name = g_strdup(o->payload_proto_name);
d->header_proto_name = g_strdup(o->header_proto_name);
@ -163,7 +163,7 @@ static void* user_copy_cb(void* dest, const void* orig, size_t len _U_)
static void user_free_cb(void* record)
{
user_encap_t *u = record;
user_encap_t *u = (user_encap_t *)record;
g_free(u->payload_proto_name);
g_free(u->header_proto_name);
@ -219,7 +219,7 @@ void proto_register_user_encap(void)
sizeof(user_encap_t),
"user_dlts",
TRUE,
(void*) &encaps,
(void**) &encaps,
&num_encaps,
UAT_AFFECTS_DISSECTION, /* affects dissection of packets, but not set of named fields */
"ChUserDLTsSection",

View File

@ -169,7 +169,7 @@ static guint num_channels_uat = 0;
UAT_DEC_CB_DEF(uat_bitchannels, channel, uat_channel_t)
static void vcdu_uat_data_update_cb(void* p, const char** err) {
uat_channel_t *ud = p;
uat_channel_t *ud = (uat_channel_t *)p;
if (ud->channel >= 64) {
*err = ep_strdup_printf("Channel must be between 0-63.");
@ -617,7 +617,7 @@ proto_register_vcdu(void)
sizeof(uat_channel_t),
"vcdu_bitstream_channels",
TRUE,
(void*)&uat_bitchannels,
(void**)&uat_bitchannels,
&num_channels_uat,
UAT_AFFECTS_DISSECTION, /* affects dissection of packets, but not set of named fields */
NULL,

View File

@ -298,7 +298,7 @@ dissect_vjuc(tvbuff_t *tvb, packet_info *pinfo, proto_tree * tree)
* Copy packet data to a buffer, and replace the connection index with
* the protocol type (which is always TCP), to give the actual IP header.
*/
buffer = tvb_memdup(tvb, 0, isize);
buffer = (guint8 *)tvb_memdup(tvb, 0, isize);
buffer[IP_FIELD_PROTOCOL] = IP_PROTO_TCP;
/* Check IP checksum */
@ -445,7 +445,7 @@ vj_init(void)
static slcompress *
slhc_init(void)
{
slcompress *comp = se_alloc0(sizeof(slcompress));
slcompress *comp = se_new0(slcompress);
int i;
/*
@ -476,7 +476,7 @@ vjc_tvb_setup(tvbuff_t *src_tvb,
DISSECTOR_ASSERT(src_tvb);
/* Get decompressed header stored in fd protocol area */
hdr_buf = p_get_proto_data(pinfo->fd, proto_vj);
hdr_buf = (vj_header_t *)p_get_proto_data(pinfo->fd, proto_vj);
if(hdr_buf == NULL) {
col_set_str(pinfo->cinfo, COL_INFO, "VJ compressed TCP (previous data bad or missing)");
return VJ_ERROR;
@ -492,7 +492,7 @@ vjc_tvb_setup(tvbuff_t *src_tvb,
hdr_len = lo_nibble(data_ptr[0]) * 4;
hdr_len += hi_nibble(data_ptr[hdr_len + 12]) * 4;
buf_len = tvb_length(src_tvb) + hdr_len - offset;
pbuf = g_malloc(buf_len);
pbuf = (guint8 *)g_malloc(buf_len);
memcpy(pbuf, data_ptr, hdr_len);
tvb_memcpy(src_tvb, pbuf + hdr_len, offset, buf_len - hdr_len);
memcpy(&tot_len, data_ptr + 2, 2);
@ -726,7 +726,7 @@ vjc_process(tvbuff_t *src_tvb, packet_info *pinfo, proto_tree *tree,
ip->cksum = ip_csum((guint8 *)ip, lo_nibble(ip->ihl_version) * 4);
/* Store the reconstructed header in frame data area */
buf_hdr = se_alloc(sizeof (vj_header_t));
buf_hdr = se_new(vj_header_t);
buf_hdr->offset = offset; /* Offset in tvbuff is also stored */
data_ptr = buf_hdr->data;
memcpy(data_ptr, ip, IP_HDR_LEN);

View File

@ -167,9 +167,9 @@ dissect_vrrp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
switch(hi_nibble(ver_type)) {
case 3:
/* Set up the fields of the pseudo-header. */
cksum_vec[0].ptr = pinfo->src.data;
cksum_vec[0].ptr = (guint8 *)pinfo->src.data;
cksum_vec[0].len = pinfo->src.len;
cksum_vec[1].ptr = pinfo->dst.data;
cksum_vec[1].ptr = (guint8 *)pinfo->dst.data;
cksum_vec[1].len = pinfo->dst.len;
cksum_vec[2].ptr = (const guint8 *)&phdr;
phdr[0] = g_htonl(vrrp_len);

View File

@ -566,7 +566,7 @@ dissect_winsrepl_replication(tvbuff_t *winsrepl_tvb, packet_info *pinfo,
}
/* REPLIICATION_CMD */
command = tvb_get_ntohl(winsrepl_tvb, winsrepl_offset);
command = (enum wrepl_replication_cmd)tvb_get_ntohl(winsrepl_tvb, winsrepl_offset);
proto_tree_add_uint(repl_tree, hf_winsrepl_replication_command, winsrepl_tvb, winsrepl_offset, 4, command);
winsrepl_offset += 4;
@ -661,7 +661,7 @@ dissect_winsrepl_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent_tree)
offset += 4;
/* MESSAGE_TYPE */
mess_type = tvb_get_ntohl(tvb, offset);
mess_type = (enum wrepl_mess_type)tvb_get_ntohl(tvb, offset);
proto_tree_add_uint(winsrepl_tree, hf_winsrepl_mess_type, tvb, offset, 4, mess_type);
offset += 4;

View File

@ -120,7 +120,7 @@ dissect_wol(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data _U_)
/* So far so good. Now get the next 6 bytes, which we'll assume is the
* target's MAC address, and do 15 memory chunk comparisons, since if this
* is a real MagicPacket, the target's MAC will be duplicated 16 times. */
mac = ep_tvb_memdup(tvb, 6, 6);
mac = (guint8 *)ep_tvb_memdup(tvb, 6, 6);
for ( offset = 12; offset < 102; offset += 6 )
if ( tvb_memeql(tvb, offset, mac, 6) != 0 )
return (0);

View File

@ -1632,7 +1632,7 @@ dissect_wps_tlvs(proto_tree *eap_tree, tvbuff_t *tvb, int offset,
if ((hf_info != NULL) && hf_info->strings) {
/* item has value_string */
proto_item_append_text(tlv_item, fmt, val_to_str(value,
hf_info->strings,
(value_string *)hf_info->strings,
"Unknown: %d"), value);
} else if (valuep != NULL) {
/* the string-case */

View File

@ -5155,7 +5155,7 @@ dissect_wsp_common(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree,
if (! found_match) {
if (! dissector_try_heuristic(heur_subdissector_list,
tmp_tvb, pinfo, tree, NULL)) {
guint8* save_private_data = pinfo->private_data;
guint8* save_private_data = (guint8 *)pinfo->private_data;
pinfo->match_string = contentTypeStr;
pinfo->private_data = NULL; /* TODO: parameters */
@ -5250,7 +5250,7 @@ dissect_wsp_common(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree,
if (! found_match) {
if (! dissector_try_heuristic(heur_subdissector_list,
tmp_tvb, pinfo, tree, NULL)) {
guint8* save_private_data = pinfo->private_data;
guint8* save_private_data = (guint8 *)pinfo->private_data;
pinfo->match_string = contentTypeStr;
pinfo->private_data = NULL; /* TODO: parameters */
@ -5334,7 +5334,7 @@ dissect_wsp_common(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree,
if (! found_match) {
if (! dissector_try_heuristic(heur_subdissector_list,
tmp_tvb, pinfo, tree, NULL)) {
guint8* save_private_data = pinfo->private_data;
guint8* save_private_data = (guint8 *)pinfo->private_data;
pinfo->match_string = contentTypeStr;
pinfo->private_data = NULL; /* TODO: parameters */
@ -5822,7 +5822,7 @@ add_post_variable (proto_tree *tree, tvbuff_t *tvb, guint variableStart, guint v
if (valueEnd < valueStart)
{
valueBuffer = ep_alloc (1);
valueBuffer = (char *)ep_alloc (1);
valueBuffer[0] = 0;
valueEnd = valueStart;
}
@ -5935,7 +5935,7 @@ add_multipart_data (proto_tree *tree, tvbuff_t *tvb, packet_info *pinfo)
if (! found_match) {
if (! dissector_try_heuristic(heur_subdissector_list,
tmp_tvb, pinfo, mpart_tree, NULL)) {
guint8* save_private_data = pinfo->private_data;
guint8* save_private_data = (guint8 *)pinfo->private_data;
pinfo->match_string = contentTypeStr;
pinfo->private_data = NULL; /* TODO: parameters */

View File

@ -341,7 +341,7 @@ dissect_wtp_common(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
gint dataLen;
#define SZINFO_SIZE 256
szInfo=ep_alloc(SZINFO_SIZE);
szInfo=(char *)ep_alloc(SZINFO_SIZE);
b0 = tvb_get_guint8 (tvb, offCur + 0);
/* Discover Concatenated PDUs */

View File

@ -656,7 +656,7 @@ static char *
dte_address_util(tvbuff_t *tvb, int offset, guint8 len)
{
int i;
char *tmpbuf = ep_alloc(258);
char *tmpbuf = (char *)ep_alloc(258);
for (i = 0; (i<len)&&(i<256); i++) {
if (i % 2 == 0) {
@ -1019,8 +1019,8 @@ x25_ntoa(proto_tree *tree, int *offset, tvbuff_t *tvb,
guint8 byte;
int localoffset;
addr1=ep_alloc(16);
addr2=ep_alloc(16);
addr1=(char *)ep_alloc(16);
addr2=(char *)ep_alloc(16);
byte = tvb_get_guint8(tvb, *offset);
len1 = (byte >> 0) & 0x0F;
@ -1100,8 +1100,8 @@ x25_toa(proto_tree *tree, int *offset, tvbuff_t *tvb,
guint8 byte;
int localoffset;
addr1=ep_alloc(256);
addr2=ep_alloc(256);
addr1=(char *)ep_alloc(256);
addr2=(char *)ep_alloc(256);
len1 = tvb_get_guint8(tvb, *offset);
if (tree) {

View File

@ -79,7 +79,7 @@ dissect_x29(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
int offset = 0;
proto_tree *x29_tree = NULL;
proto_item *ti;
gboolean *q_bit_set = pinfo->private_data;
gboolean *q_bit_set = (gboolean *)pinfo->private_data;
guint8 msg_code;
guint8 error_type;
guint8 type_ref;

View File

@ -892,9 +892,9 @@ dissect_xmcp_message(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
conversation = find_or_create_conversation(pinfo);
/* Do we already have XMCP state for this conversation? */
xmcp_conv_info = conversation_get_proto_data(conversation, proto_xmcp);
xmcp_conv_info = (xmcp_conv_info_t *)conversation_get_proto_data(conversation, proto_xmcp);
if (!xmcp_conv_info) {
xmcp_conv_info = se_alloc(sizeof(xmcp_conv_info_t));
xmcp_conv_info = se_new(xmcp_conv_info_t);
xmcp_conv_info->transaction_pdus =
se_tree_create_non_persistent(EMEM_TREE_TYPE_RED_BLACK,
"xmcp_pdus");
@ -902,10 +902,10 @@ dissect_xmcp_message(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
}
/* Find existing transaction entry or create a new one */
xmcp_trans = se_tree_lookup32_array(xmcp_conv_info->transaction_pdus,
xmcp_trans = (xmcp_transaction_t *)se_tree_lookup32_array(xmcp_conv_info->transaction_pdus,
transaction_id_key);
if (!xmcp_trans) {
xmcp_trans = se_alloc(sizeof(xmcp_transaction_t));
xmcp_trans = se_new(xmcp_transaction_t);
xmcp_trans->request_frame = 0;
xmcp_trans->response_frame = 0;
xmcp_trans->request_time = pinfo->fd->abs_ts;

View File

@ -955,7 +955,7 @@ dissect_xtp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data _U_)
xtph->seq += tvb_get_ntohl(tvb, offset+4);
#define MAX_OPTIONS_LEN 128
options=ep_alloc(MAX_OPTIONS_LEN);
options=(gchar *)ep_alloc(MAX_OPTIONS_LEN);
options[0]=0;
cmd_options = xtph->cmd_options >> 8;
for (i = 0; i < 16; i++) {

View File

@ -367,11 +367,11 @@ dissect_zbee_nwk(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
/* Set up hint structures */
if (!pinfo->fd->flags.visited) {
/* Allocate frame data with hints for upper layers */
nwk_hints = se_alloc0(sizeof(zbee_nwk_hints_t));
nwk_hints = se_new0(zbee_nwk_hints_t);
p_add_proto_data(pinfo->fd, proto_zbee_nwk, nwk_hints);
} else {
/* Retrieve existing structure */
nwk_hints = p_get_proto_data(pinfo->fd, proto_zbee_nwk);
nwk_hints = (zbee_nwk_hints_t *)p_get_proto_data(pinfo->fd, proto_zbee_nwk);
}
ieee_hints = (ieee802154_hints_t *)p_get_proto_data(pinfo->fd,

View File

@ -418,8 +418,8 @@ dissect_zbee_zdp_req_set_user_desc(tvbuff_t *tvb, packet_info *pinfo, proto_tree
/* No Length field in ZigBee 2003 & earlier, uses a fixed length of 16. */
user_length = 16;
}
user = ep_alloc(user_length+1);
user = tvb_memcpy(tvb, user, offset, user_length);
user = (gchar *)ep_alloc(user_length+1);
user = (gchar *)tvb_memcpy(tvb, user, offset, user_length);
user[user_length] = '\0';
if (tree) {
proto_tree_add_string(tree, hf_zbee_zdp_user, tvb, offset, user_length, user);

View File

@ -1014,8 +1014,8 @@ zdp_parse_complex_desc(proto_tree *tree, gint ettindex, tvbuff_t *tvb, guint *of
proto_item *field_root;
proto_tree *field_tree;
gchar *str = ep_alloc(length);
gchar *complex = ep_alloc(max_len);
gchar *str = (gchar *)ep_alloc(length);
gchar *complex = (gchar *)ep_alloc(max_len);
guint8 tag;
if ((tree) && (ettindex != -1)) {

View File

@ -459,7 +459,7 @@ static void
dissect_Conf2ACK(packet_info *pinfo) {
/* Signals start of SRT(C)P streams */
struct srtp_info *dummy_srtp_info = se_alloc0(sizeof(struct srtp_info));
struct srtp_info *dummy_srtp_info = se_new0(struct srtp_info);
dummy_srtp_info->encryption_algorithm = SRTP_ENC_ALG_AES_CM;
dummy_srtp_info->auth_algorithm = SRTP_AUTH_ALG_HMAC_SHA1;