aboutsummaryrefslogtreecommitdiff
path: root/hw
diff options
context:
space:
mode:
Diffstat (limited to 'hw')
-rw-r--r--hw/block/onenand.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/hw/block/onenand.c b/hw/block/onenand.c
index 60d5311d04..5388122eb8 100644
--- a/hw/block/onenand.c
+++ b/hw/block/onenand.c
@@ -335,9 +335,7 @@ static inline int onenand_prog_spare(OneNANDState *s, int sec, int secn,
dp, 1) < 0;
}
}
- if (dp) {
- g_free(dp);
- }
+ g_free(dp);
}
return result;
}