Package: kgb-client Severity: normal Tags: patch When a commit is done, kgb-client tries to map login to real name. But if user isn't local, then it fails and just displays nothing. This patch makes the login default name and only uses real name if available. Tested successfully
-- System Information: Debian Release: 8.0 APT prefers unstable APT policy: (500, 'unstable') Architecture: amd64 (x86_64) Foreign Architectures: i386 Kernel: Linux 3.16.0-4-amd64 (SMP w/8 CPU cores) Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/dash Init: systemd (via /run/systemd/system)
>From 69053894a842e530fb7c40ed0dc62026ce6d8dee Mon Sep 17 00:00:00 2001 From: Pierre Schweitzer <pie...@reactos.org> Date: Wed, 10 Dec 2014 19:36:42 +0100 Subject: [PATCH] In case the commiter isn't a local user, don't attempt to use $user which won't be defined and fallback to login name --- lib/App/KGB/Client.pm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/App/KGB/Client.pm b/lib/App/KGB/Client.pm index eca2b74..b38ef63 100644 --- a/lib/App/KGB/Client.pm +++ b/lib/App/KGB/Client.pm @@ -1055,7 +1055,8 @@ sub _get_full_user_name { return $self->_full_user_name if $self->_full_user_name; my $user = getpwnam($login); - ( my $full_name = $user->gecos ) =~ s/,.*//; + my $full_name = $login + ( $full_name = $user->gecos ) =~ s/,.*// if defined $user; utf8::decode($full_name); -- 1.9.1