projects
/
firefly-linux-kernel-4.4.55.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
pstore: Fix NULL pointer fault if get NULL prz in ramoops_get_next_prz
[firefly-linux-kernel-4.4.55.git]
/
fs
/
pstore
/
ram.c
diff --git
a/fs/pstore/ram.c
b/fs/pstore/ram.c
index e0e42b5a691ced15ce979fbd6944028c2010f3a3..d3d37142bd93b49c9e3d6c0b11063d8af17d15f3 100644
(file)
--- a/
fs/pstore/ram.c
+++ b/
fs/pstore/ram.c
@@
-125,6
+125,8
@@
ramoops_get_next_prz(struct persistent_ram_zone *przs[], uint *c, uint max,
return NULL;
prz = przs[i];
+ if (!prz)
+ return NULL;
/* Update old/shadowed buffer. */
if (update)