Cleanup: standardization of indentations in tsock_texte and tsock_video
This commit is contained in:
parent
95be64764a
commit
3f7c447bef
2 changed files with 34 additions and 34 deletions
26
tsock_texte
26
tsock_texte
|
@ -7,22 +7,22 @@ protocol="tcp"
|
|||
usage() { echo "Usage: $0 [-p|-s]" 1>&2; exit 1; }
|
||||
|
||||
while getopts "pst:" o; do
|
||||
case "${o}" in
|
||||
p)
|
||||
puits=true
|
||||
;;
|
||||
s)
|
||||
sourc=true
|
||||
;;
|
||||
*)
|
||||
usage
|
||||
;;
|
||||
esac
|
||||
case "${o}" in
|
||||
p)
|
||||
puits=true
|
||||
;;
|
||||
s)
|
||||
sourc=true
|
||||
;;
|
||||
*)
|
||||
usage
|
||||
;;
|
||||
esac
|
||||
done
|
||||
|
||||
if ([ "$puits" = true ] && [ "$sourc" = true ]) || ([ "$puits" = false ] && [ "$sourc" = false ]) ; then
|
||||
usage
|
||||
exit 1
|
||||
usage
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ "$puits" = true ]; then
|
||||
|
|
42
tsock_video
42
tsock_video
|
@ -7,29 +7,29 @@ protocol="tcp"
|
|||
usage() { echo "Usage: $0 [[-p|-s] [-t (tcp|mictcp)]" 1>&2; exit 1; }
|
||||
|
||||
while getopts "pst:" o; do
|
||||
case "${o}" in
|
||||
t)
|
||||
protocol=${OPTARG}
|
||||
if [ "$protocol" != "tcp" ] && [ "$protocol" != "mictcp" ]; then
|
||||
usage
|
||||
exit 1
|
||||
fi
|
||||
;;
|
||||
p)
|
||||
puits=true
|
||||
;;
|
||||
s)
|
||||
sourc=true
|
||||
;;
|
||||
*)
|
||||
usage
|
||||
;;
|
||||
esac
|
||||
case "${o}" in
|
||||
t)
|
||||
protocol=${OPTARG}
|
||||
if [ "$protocol" != "tcp" ] && [ "$protocol" != "mictcp" ]; then
|
||||
usage
|
||||
exit 1
|
||||
fi
|
||||
;;
|
||||
p)
|
||||
puits=true
|
||||
;;
|
||||
s)
|
||||
sourc=true
|
||||
;;
|
||||
*)
|
||||
usage
|
||||
;;
|
||||
esac
|
||||
done
|
||||
|
||||
if ([ "$puits" = true ] && [ "$sourc" = true ]) || ([ "$puits" = false ] && [ "$sourc" = false ]) ; then
|
||||
usage
|
||||
exit 1
|
||||
usage
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ "$puits" = true ]; then
|
||||
|
@ -40,7 +40,7 @@ if [ "$puits" = true ]; then
|
|||
if [ "$protocol" = "mictcp" ]; then
|
||||
cd build
|
||||
./gateway -p -t $protocol 1234 &
|
||||
cd ..
|
||||
cd ..
|
||||
fi
|
||||
fi
|
||||
|
||||
|
|
Loading…
Reference in a new issue