[PATCH 5/7] maint: function returning "int", did not return a value.
Jim Meyering
meyering at redhat.com
Tue Sep 29 20:02:56 UTC 2009
* parted/ui.c (init_readline): Return a value (always 0 for now).
* parted/parted.c (_init): Handle init_readline's return value.
---
parted/parted.c | 3 ++-
parted/ui.c | 1 +
2 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/parted/parted.c b/parted/parted.c
index 55627bf..0dd11d2 100644
--- a/parted/parted.c
+++ b/parted/parted.c
@@ -2461,7 +2461,8 @@ if (!_parse_options (argc_ptr, argv_ptr))
goto error_done_commands;
if (!opt_script_mode)
- init_readline ();
+ if (init_readline ())
+ goto error_done_commands;
#ifdef HAVE_GETUID
if (getuid() != 0 && !opt_script_mode) {
diff --git a/parted/ui.c b/parted/ui.c
index 1fa10b7..295edba 100644
--- a/parted/ui.c
+++ b/parted/ui.c
@@ -1402,6 +1402,7 @@ init_readline (void)
readline_state.in_readline = 0;
}
#endif
+ return 0;
}
int
--
1.6.5.rc2.177.ga9dd6
More information about the parted-devel
mailing list