Skip to content

Commit

Permalink
Missing fixes added
Browse files Browse the repository at this point in the history
Signed-off-by: Vivek Reddy Karri <vkarri@nvidia.com>
  • Loading branch information
vivekrnv committed Sep 29, 2021
1 parent 86919fa commit c8b913e
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions scripts/generate_dump
Original file line number Diff line number Diff line change
Expand Up @@ -86,8 +86,9 @@ save_bcmcmd() {
if [ $ret -eq 124 ]; then
echo "Command: $cmd timedout after ${TIMEOUT_MIN} minutes."
else
grep "polling socket timeout: Success" ${filepath} &>/dev/null
if [ $? -eq 0 ]; then
RC=0
grep "polling socket timeout: Success" ${filepath} &>/dev/null || RC=$?
if [ $RC -eq 0 ]; then
echo "bcmcmd command timeout. Setting SKIP_BCMCMD to true ..."
SKIP_BCMCMD=1
fi
Expand Down Expand Up @@ -187,8 +188,9 @@ save_cmd() {
if $NOOP; then
echo "${timeout_cmd} bash -c \"${cmds}\""
else
eval "${timeout_cmd} bash -c \"${cmds}\""
if [ $? -ne 0 ]; then
RC=0
eval "${timeout_cmd} bash -c \"${cmds}\"" || RC=$?
if [ $RC -ne 0 ]; then
echo "Command: $cmds timedout after ${TIMEOUT_MIN} minutes."
fi
fi
Expand Down

0 comments on commit c8b913e

Please sign in to comment.