From ca4dc54bcdea6c06c219f10e1b9488d724934517 Mon Sep 17 00:00:00 2001 From: jtc Date: Thu, 23 Nov 1995 02:07:34 +0000 Subject: [PATCH] Handle '&' in gecos field --- gnu/usr.bin/send-pr/send-pr.sh | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/gnu/usr.bin/send-pr/send-pr.sh b/gnu/usr.bin/send-pr/send-pr.sh index 48bd9d3a7150..5a329d09d4d5 100644 --- a/gnu/usr.bin/send-pr/send-pr.sh +++ b/gnu/usr.bin/send-pr/send-pr.sh @@ -111,6 +111,14 @@ else $PASSWD | grep "^$LOGNAME:" | awk -F: '{print $5}' | sed -e 's/,.*//' > $TEMP ORIGINATOR="`cat $TEMP`" rm -f $TEMP + + case "$ORIGINATOR" in + *'&'*) + TEMP=`echo $LOGNAME | tr '[a-z]' '[A-Z]'` + TEMP=`echo $TEMP $LOGNAME | sed 's/^\(.\)[^ ]* ./\1/'` + ORIGINATOR=`echo "$ORIGINATOR" | sed "s/&/$TEMP/"` + ;; + esac fi if [ -n "$ORGANIZATION" ]; then