rtl8188eu: Place guard code in _rtw_open_pktfile()

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
This commit is contained in:
Larry Finger 2017-01-16 15:23:52 -06:00
parent ce54314518
commit 0ebfaa07e4

View file

@ -40,6 +40,14 @@ uint rtw_remainder_len(struct pkt_file *pfile)
void _rtw_open_pktfile(struct sk_buff *pktptr, struct pkt_file *pfile) void _rtw_open_pktfile(struct sk_buff *pktptr, struct pkt_file *pfile)
{ {
if (!pktptr) {
pr_err("8188eu: pktptr is NULL\n");
return;
}
if (!pfile) {
pr_err("8188eu: pfile is NULL\n");
return;
}
pfile->pkt = pktptr; pfile->pkt = pktptr;
pfile->cur_addr = pktptr->data; pfile->cur_addr = pktptr->data;
pfile->buf_start = pktptr->data; pfile->buf_start = pktptr->data;