0010-scripts-use-proper-arithmetic-operations.patch 1.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. From 66ae6e5313da8be5742a502c0d7027689e84a17d Mon Sep 17 00:00:00 2001
  2. From: Ioana Ciornei <[email protected]>
  3. Date: Wed, 25 Oct 2017 11:30:08 +0000
  4. Subject: [PATCH 10/12] scripts: use proper arithmetic operations
  5. Signed-off-by: Ioana Ciornei <[email protected]>
  6. ---
  7. scripts/ls-main | 6 +++---
  8. 1 file changed, 3 insertions(+), 3 deletions(-)
  9. diff --git a/scripts/ls-main b/scripts/ls-main
  10. index 7ce73f0..0dcd2fa 100755
  11. --- a/scripts/ls-main
  12. +++ b/scripts/ls-main
  13. @@ -409,7 +409,7 @@ process_addmux() {
  14. # check the status
  15. object_exists $container $dpdmux
  16. - if (( $object_exists_status == 1 )); then
  17. + if [ $object_exists_status == 1 ]; then
  18. if [ "$root_c" == "$container" ]; then
  19. evb=$(ls $SYS_DPRC/"$root_c"/"$dpdmux"/net/ | grep -v "p")
  20. @@ -598,7 +598,7 @@ process_addsw() {
  21. # check the status
  22. object_exists $container $dpsw
  23. - if (( $object_exists_status == 1 )); then
  24. + if [ $object_exists_status == 1 ]; then
  25. echo "Created ETHSW object $dpsw with ${num_ifs} ports"
  26. if [ $num_ifs -gt $ifcnt ]; then
  27. @@ -850,7 +850,7 @@ process_addni() {
  28. # check the status
  29. object_exists $container $dpni
  30. - if (( $object_exists_status == 1 )); then
  31. + if [ $object_exists_status == 1 ]; then
  32. if [ "$root_c" == "$container" ]; then
  33. ni=$(ls $SYS_DPRC/"$root_c"/"$dpni"/net/)
  34. fi
  35. --
  36. 2.14.1