diff options
author | Anders Broman <anders.broman@ericsson.com> | 2013-03-19 04:54:30 +0000 |
---|---|---|
committer | Anders Broman <anders.broman@ericsson.com> | 2013-03-19 04:54:30 +0000 |
commit | a10b98284c44bcafc86ee440ce936cfe305fe01b (patch) | |
tree | ff1ad5ac23bc527b2cccdff6e73ba401bd04d5f5 /epan/stream.c | |
parent | bab72ca73439280d7b83d40495d8a39d46267ddc (diff) |
From beroset:
remove C++ incompatibilities
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8416
svn path=/trunk/; revision=48412
Diffstat (limited to 'epan/stream.c')
-rw-r--r-- | epan/stream.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/epan/stream.c b/epan/stream.c index 1784c7d312..66ee51b763 100644 --- a/epan/stream.c +++ b/epan/stream.c @@ -156,7 +156,7 @@ static stream_t *new_stream( stream_key_t *key ) { stream_t *val; - val = se_alloc(sizeof(stream_t)); + val = se_new(stream_t); val -> key = key; val -> pdu_counter = 0; val -> current_pdu = NULL; @@ -173,7 +173,7 @@ static stream_t *stream_hash_insert_circ( const struct circuit *circuit, int p2p { stream_key_t *key; - key = se_alloc(sizeof(stream_key_t)); + key = se_new(stream_key_t); key->is_circuit = TRUE; key->circ.circuit = circuit; key->p2p_dir = p2p_dir; @@ -185,7 +185,7 @@ static stream_t *stream_hash_insert_conv( const struct conversation *conv, int p { stream_key_t *key; - key = se_alloc(sizeof(stream_key_t)); + key = se_new(stream_key_t); key->is_circuit = FALSE; key->circ.conv = conv; key->p2p_dir = p2p_dir; @@ -216,7 +216,7 @@ static void stream_init_pdu_data(void) static stream_pdu_t *stream_new_pdu(stream_t *stream) { stream_pdu_t *pdu; - pdu = se_alloc(sizeof(stream_pdu_t)); + pdu = se_new(stream_pdu_t); pdu -> fd_head = NULL; pdu -> pdu_number = stream -> pdu_counter++; pdu -> id = pdu_counter++; @@ -283,7 +283,7 @@ static stream_pdu_fragment_t *fragment_hash_lookup( const stream_t *stream, guin key.stream = stream; key.framenum = framenum; key.offset = offset; - val = g_hash_table_lookup(fragment_hash, &key); + val = (stream_pdu_fragment_t *)g_hash_table_lookup(fragment_hash, &key); return val; } @@ -296,12 +296,12 @@ static stream_pdu_fragment_t *fragment_hash_insert( const stream_t *stream, guin fragment_key_t *key; stream_pdu_fragment_t *val; - key = se_alloc(sizeof(fragment_key_t)); + key = se_new(fragment_key_t); key->stream = stream; key->framenum = framenum; key->offset = offset; - val = se_alloc(sizeof(stream_pdu_fragment_t)); + val = se_new(stream_pdu_fragment_t); val->len = length; val->pdu = NULL; val->final_fragment = FALSE; |