summaryrefslogtreecommitdiffstats
path: root/stream/stream_netstream.h
diff options
context:
space:
mode:
authordiego <diego@b3059339-0415-0410-9bf9-f77b7e298cf2>2010-02-26 15:01:37 +0000
committerdiego <diego@b3059339-0415-0410-9bf9-f77b7e298cf2>2010-02-26 15:01:37 +0000
commitb63759b175cf9ddd9735ca0d2f803fe62f69c3c3 (patch)
treea583febda46545afc4ed20ccbdbed0ae3165a5c4 /stream/stream_netstream.h
parentfad137d7fe3bfef6a258518a1e86a4d811d3b4b5 (diff)
downloadmpv-b63759b175cf9ddd9735ca0d2f803fe62f69c3c3.tar.bz2
mpv-b63759b175cf9ddd9735ca0d2f803fe62f69c3c3.tar.xz
Do not cast the results of malloc/calloc/realloc.
These functions return void*, which is compatible with any pointer, so there is no need for casts. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@30744 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'stream/stream_netstream.h')
-rw-r--r--stream/stream_netstream.h3
1 files changed, 1 insertions, 2 deletions
diff --git a/stream/stream_netstream.h b/stream/stream_netstream.h
index a81bc37c83..4d3e30e849 100644
--- a/stream/stream_netstream.h
+++ b/stream/stream_netstream.h
@@ -89,8 +89,7 @@ static int net_read(int fd, char* buf, int len) {
static mp_net_stream_packet_t* read_packet(int fd) {
uint16_t len;
- mp_net_stream_packet_t* pack =
- (mp_net_stream_packet_t*)malloc(sizeof(mp_net_stream_packet_t));
+ mp_net_stream_packet_t* pack = malloc(sizeof(mp_net_stream_packet_t));
if(!net_read(fd,(char*)pack,sizeof(mp_net_stream_packet_t))) {
free(pack);