Fix protoc-gen-nanopb when the path contains spaces
authorPetteri Aimonen <jpa@git.mail.kapsi.fi>
Sun, 29 Dec 2013 18:48:30 +0000 (20:48 +0200)
committerPetteri Aimonen <jpa@git.mail.kapsi.fi>
Sun, 29 Dec 2013 18:48:30 +0000 (20:48 +0200)
generator/protoc-gen-nanopb

index 90be6a5..2de5621 100755 (executable)
@@ -9,4 +9,5 @@
 # path is already set up properly and there is no need to give
 # --plugin= on the command line.
 
-exec python $(dirname $0)/nanopb_generator.py --protoc-plugin
+MYPATH=$(dirname "$0")
+exec python "$MYPATH/nanopb_generator.py" --protoc-plugin