summaryrefslogtreecommitdiffstats
path: root/lib/kasprintf.c
diff options
context:
space:
mode:
authorRoger Pau Monne <roger.pau@citrix.com>2013-07-31 17:00:42 +0200
committerKonrad Rzeszutek Wilk <konrad.wilk@oracle.com>2013-08-09 10:58:11 -0400
commit5f338d9001094a56cf87bd8a280b4e7ff953bb59 (patch)
treedaef4ba1e3c1ecfa3e6dc8f87a21197911f78fc2 /lib/kasprintf.c
parente2683957fb268c6b29316fd9e7191e13239a30a5 (diff)
downloadop-kernel-dev-5f338d9001094a56cf87bd8a280b4e7ff953bb59.zip
op-kernel-dev-5f338d9001094a56cf87bd8a280b4e7ff953bb59.tar.gz
xen-gnt: prevent adding duplicate gnt callbacks
With the current implementation, the callback in the tail of the list can be added twice, because the check done in gnttab_request_free_callback is bogus, callback->next can be NULL if it is the last callback in the list. If we add the same callback twice we end up with an infinite loop, were callback == callback->next. Replace this check with a proper one that iterates over the list to see if the callback has already been added. Signed-off-by: Roger Pau Monné <roger.pau@citrix.com> Cc: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com> Cc: David Vrabel <david.vrabel@citrix.com> Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com> Acked-by: Matt Wilson <msw@amazon.com> Reviewed-by: David Vrabel <david.vrabel@citrix.com> CC: stable@vger.kernel.org
Diffstat (limited to 'lib/kasprintf.c')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud