From 319e8ee03c88002cf7a3f4da49b3ecbc29eb698e Mon Sep 17 00:00:00 2001 From: Ben Cressey Date: Fri, 6 Sep 2013 12:52:06 -0700 Subject: minios: clean up unneeded "err = NULL" in frontend drivers This patch removes cases where the error message pointer is already NULL and is then set to NULL. These are harmless, but suggest incorrect practice: the pointer should be passed to free() to deallocate memory prior to reassignment. There are no functional changes in this patch. Signed-off-by: Ben Cressey Reviewed-by: Matt Wilson Cc: Stefano Stabellini Acked-by: Samuel Thibault [msw: split a larger patch from Ben into this cleanup patch] Signed-off-by: Matt Wilson --- extras/mini-os/fbfront.c | 3 --- 1 file changed, 3 deletions(-) (limited to 'extras/mini-os/fbfront.c') diff --git a/extras/mini-os/fbfront.c b/extras/mini-os/fbfront.c index 9148496953..8b4466a590 100644 --- a/extras/mini-os/fbfront.c +++ b/extras/mini-os/fbfront.c @@ -272,7 +272,6 @@ void shutdown_kbdfront(struct kbdfront_dev *dev) XenbusStateInitialising, err); goto close_kbdfront; } - err = NULL; state = xenbus_read_integer(path); while (err == NULL && (state < XenbusStateInitWait || state >= XenbusStateClosed)) err = xenbus_wait_for_state_change(path, &state, &dev->events); @@ -664,8 +663,6 @@ void shutdown_fbfront(struct fbfront_dev *dev) XenbusStateInitialising, err); goto close_fbfront; } - - err = NULL; state = xenbus_read_integer(path); while (err == NULL && (state < XenbusStateInitWait || state >= XenbusStateClosed)) err = xenbus_wait_for_state_change(path, &state, &dev->events); -- cgit v1.2.3