argv: Sanitizing wildcards argv: Sanitizing wildcards shell shell

argv: Sanitizing wildcards


The shell is expanding the glob before executing the program. You quote the glob not because of GCC, but because of the shell. If you don't want this behavior then use a shell that does not honor globs.


Give input as

$./rpn "5 10 *" 

All argument in "" and in program you will get all argument under argv[1] then parse that string by space separation.

By this way you do need to handle any wildcard/special character at special way.