summaryrefslogtreecommitdiffstats
path: root/net/caif/cfvidl.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/caif/cfvidl.c')
-rw-r--r--net/caif/cfvidl.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/net/caif/cfvidl.c b/net/caif/cfvidl.c
index e3f37db..a8e2a2d 100644
--- a/net/caif/cfvidl.c
+++ b/net/caif/cfvidl.c
@@ -50,8 +50,12 @@ static int cfvidl_transmit(struct cflayer *layr, struct cfpkt *pkt)
struct caif_payload_info *info;
u32 videoheader = 0;
int ret;
- if (!cfsrvl_ready(service, &ret))
+
+ if (!cfsrvl_ready(service, &ret)) {
+ cfpkt_destroy(pkt);
return ret;
+ }
+
cfpkt_add_head(pkt, &videoheader, 4);
/* Add info for MUX-layer to route the packet out */
info = cfpkt_info(pkt);
OpenPOWER on IntegriCloud