From 9ebb429f666adeb32f607e4494555f0537ef7f28 Mon Sep 17 00:00:00 2001 From: Cameron Gutman Date: Sun, 21 May 2017 10:59:47 -0700 Subject: [PATCH] Fix null check typo --- src/ControlStream.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/ControlStream.c b/src/ControlStream.c index 65299c3..62377fb 100644 --- a/src/ControlStream.c +++ b/src/ControlStream.c @@ -322,7 +322,7 @@ static int sendMessageEnet(short ptype, short paylen, const void* payload) { } enetPacket = enet_packet_create(packet, sizeof(*packet) + paylen, ENET_PACKET_FLAG_RELIABLE); - if (packet == NULL) { + if (enetPacket == NULL) { free(packet); return 0; }