login

<     >

2021-09-08 11:49:25 (UTC-03:00)

Marcel Rodrigues <marcelgmr@gmail.com>

use POSIX parameter substitution

diff --git a/neatcc b/neatcc
index 829e6b5..6b0c976 100755
--- a/neatcc
+++ b/neatcc
@@ -72,11 +72,11 @@ for arg in "$@"; do
                 case "$arg" in
                     *.s)
                         asm_sources="$asm_sources $arg"
-                        object=${arg//.s/.o}
+                        object=${arg%.s}.o
                     ;;
                     *.c)
                         c_sources="$c_sources $arg"
-                        object=${arg//.c/.o}
+                        object=${arg%.c}.o
                     ;;
                     *.o)
                         object="$arg"