diff --git a/tsock_texte b/tsock_texte index 64ac6bc..343ffc6 100755 --- a/tsock_texte +++ b/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 diff --git a/tsock_video b/tsock_video index 5b61f65..7a43230 100755 --- a/tsock_video +++ b/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