summaryrefslogtreecommitdiff
path: root/contrib/process_log.sh
diff options
context:
space:
mode:
authorBart Polot <bart@net.in.tum.de>2015-10-02 03:37:49 +0000
committerBart Polot <bart@net.in.tum.de>2015-10-02 03:37:49 +0000
commitea4df299159c854db3e04244455c7628d94a66a2 (patch)
treebb6105b1f30a5ce090dcd36f45cc6535e3aaf0c9 /contrib/process_log.sh
parentf25401600fa588da62c79fd91031664098624aa5 (diff)
- escape line to avoid false matches
Diffstat (limited to 'contrib/process_log.sh')
-rwxr-xr-xcontrib/process_log.sh6
1 files changed, 3 insertions, 3 deletions
diff --git a/contrib/process_log.sh b/contrib/process_log.sh
index baade73d9..c25c515c2 100755
--- a/contrib/process_log.sh
+++ b/contrib/process_log.sh
@@ -9,9 +9,9 @@ grep "STARTING SERVICE " log > __tmp_peers
SED_EXPR=""
while read -r line; do
- SRVC=`echo $line | sed -e 's/.*(\([^)]*\)).*/\1/'`
- PEER=`echo $line | sed -e 's/.*\[\(....\)\].*/\1/'`
- PID=`echo $line | sed -e "s/.*$SRVC-\([0-9]*\).*/\1/"`
+ SRVC=`echo "$line" | sed -e 's/.*(\([^)]*\)).*/\1/'`
+ PEER=`echo "$line" | sed -e 's/.*\[\(....\)\].*/\1/'`
+ PID=`echo "$line" | sed -e "s/.*$SRVC-\([0-9]*\).*/\1/"`
echo "$SRVC $PID => $PEER"
SED_EXPR="${SED_EXPR}s/$SRVC-\([a-z2]*\)-$PID/$SRVC \1 $PEER/;"