summaryrefslogtreecommitdiffhomepage
path: root/cli-runopts.c
diff options
context:
space:
mode:
authoriquaba <cooka2011@gmail.com>2014-08-06 08:48:43 -0500
committeriquaba <cooka2011@gmail.com>2014-08-06 08:48:43 -0500
commite815e974407b734f62058a4a834e6af21a937883 (patch)
treea35840d62b2c0d109aef0e0b3afb6340d20d406c /cli-runopts.c
parent0e7409c7ff6fc760018fce3d5e8b72247bf782b5 (diff)
Try without identifying current user
Small change that warns the user if the current user cannot be identified rather than aborting. This came in handy when I put dropbear on a dlink that did not have a true user environment. Falling back on the "-l" option and user@ options works just fine as a client. The only implication I found is that the -J option will fail ungracefully without a known own_user.
Diffstat (limited to 'cli-runopts.c')
-rw-r--r--cli-runopts.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/cli-runopts.c b/cli-runopts.c
index 5f36f7c..8c9bc8e 100644
--- a/cli-runopts.c
+++ b/cli-runopts.c
@@ -684,7 +684,7 @@ static void fill_own_user() {
pw = getpwuid(uid);
if (pw == NULL || pw->pw_name == NULL) {
- dropbear_exit("Unknown own user");
+ dropbear_log(LOG_INFO, "Warning: failed to identify current user. Trying anyway.");
}
cli_opts.own_user = m_strdup(pw->pw_name);