projects
/
linux-2.6-block.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
a1ca829
)
PM: hibernate: Do not initialize error in swap_write_page()
author
Li zeming
<zeming@nfschina.com>
Fri, 27 Oct 2023 01:55:33 +0000
(09:55 +0800)
committer
Rafael J. Wysocki
<rafael.j.wysocki@intel.com>
Mon, 11 Dec 2023 21:06:15 +0000
(22:06 +0100)
'error' first receives the function result before it is used, and it
does not need to be assigned a value during definition.
Signed-off-by: Li zeming <zeming@nfschina.com>
[ rjw: Subject rewrite ]
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
kernel/power/swap.c
patch
|
blob
|
blame
|
history
diff --git
a/kernel/power/swap.c
b/kernel/power/swap.c
index a2cb0babb5ec9e5c5f6321e22ecffccdd45030b8..68973ca2cf07a71a78374ea0b821662bf3b68b4f 100644
(file)
--- a/
kernel/power/swap.c
+++ b/
kernel/power/swap.c
@@
-451,7
+451,7
@@
err_close:
static int swap_write_page(struct swap_map_handle *handle, void *buf,
struct hib_bio_batch *hb)
{
- int error
= 0
;
+ int error;
sector_t offset;
if (!handle->cur)