X-Git-Url: https://git.proxmox.com/?a=blobdiff_plain;f=hw%2F9pfs%2F9p.c;h=df8aa726c9a19743d854a16c82196175814f09d7;hb=6868a420c519d74926ea814d48f6ce9beda35b98;hp=f2ab1dfab2b2899ccdd364d9e33a1117039347af;hpb=8440e22ec1a5deabc4fcf5c4826d5c73ddc15765;p=mirror_qemu.git diff --git a/hw/9pfs/9p.c b/hw/9pfs/9p.c index f2ab1dfab2..df8aa726c9 100644 --- a/hw/9pfs/9p.c +++ b/hw/9pfs/9p.c @@ -626,16 +626,14 @@ V9fsPDU *pdu_alloc(V9fsState *s) void pdu_free(V9fsPDU *pdu) { - if (pdu) { - V9fsState *s = pdu->s; - /* - * Cancelled pdu are added back to the freelist - * by flush request . - */ - if (!pdu->cancelled) { - QLIST_REMOVE(pdu, next); - QLIST_INSERT_HEAD(&s->free_list, pdu, next); - } + V9fsState *s = pdu->s; + /* + * Cancelled pdu are added back to the freelist + * by flush request . + */ + if (!pdu->cancelled) { + QLIST_REMOVE(pdu, next); + QLIST_INSERT_HEAD(&s->free_list, pdu, next); } }