Skip to content
Snippets Groups Projects
Commit ceed291c authored by Fernando Herrero's avatar Fernando Herrero
Browse files

Add topic/service/action name check for invalid slash '/' characters, which...

Add topic/service/action name check for invalid slash '/' characters, which created invalid function and variable names.
parent a05169c2
No related branches found
No related tags found
1 merge request!2Topic slash check
......@@ -40,7 +40,12 @@ do
ros_pkg=$OPTARG
;;
a)
action_name=$OPTARG
if echo "$OPTARG" | grep -q "/"; then
kill_exit "ERROR: argument -$OPTION can't contain slash '/' characters"
exit
else
action_name=$OPTARG
fi
;;
m)
action_file=$OPTARG
......
......@@ -40,7 +40,12 @@ do
ros_pkg=$OPTARG
;;
s)
service_name=$OPTARG
if echo "$OPTARG" | grep -q "/"; then
kill_exit "ERROR: argument -$OPTION can't contain slash '/' characters"
exit
else
service_name=$OPTARG
fi
;;
m)
srv_file=$OPTARG
......
......@@ -41,7 +41,12 @@ do
ros_pkg=$OPTARG
;;
t)
topic_name=$OPTARG
if echo "$OPTARG" | grep -q "/"; then
kill_exit "ERROR: argument -$OPTION can't contain slash '/' characters"
exit
else
topic_name=$OPTARG
fi
;;
m)
msg_file=$OPTARG
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment