/* Decrease the reference count of the net buffer by one. Free the associated net vector and itself if the reference count of the net buffer is decreased to 0. The net vector free operation just decrease the reference count of the net vector by one and do the real resource free operation when the reference count of the net vector is 0. */
VOID EFIAPI NetbufFree(IN NET_BUF *Nbuf)
/* Decrease the reference count of the net buffer by one. Free the associated net vector and itself if the reference count of the net buffer is decreased to 0. The net vector free operation just decrease the reference count of the net vector by one and do the real resource free operation when the reference count of the net vector is 0. */
VOID EFIAPI NetbufFree(IN NET_BUF *Nbuf)
{
  ASSERT (Nbuf != NULL);
  NET_CHECK_SIGNATURE (Nbuf, NET_BUF_SIGNATURE);
  ASSERT (Nbuf->RefCnt > 0);
  Nbuf->RefCnt--;
  if (Nbuf->RefCnt == 0) {
    NetbufFreeVector (Nbuf->Vector);
    FreePool (Nbuf);
  }
}