summaryrefslogtreecommitdiffstats
path: root/generator/nanopb_generator.py
diff options
context:
space:
mode:
Diffstat (limited to 'generator/nanopb_generator.py')
-rwxr-xr-xgenerator/nanopb_generator.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/generator/nanopb_generator.py b/generator/nanopb_generator.py
index 2f2e8531..7c60ebe9 100755
--- a/generator/nanopb_generator.py
+++ b/generator/nanopb_generator.py
@@ -15,6 +15,7 @@ except:
try:
import google.protobuf.text_format as text_format
+ import google.protobuf.descriptor_pb2 as descriptor
except:
sys.stderr.write('''
*************************************************************
@@ -26,7 +27,7 @@ except:
try:
import proto.nanopb_pb2 as nanopb_pb2
- import proto.descriptor_pb2 as descriptor
+ import proto.plugin_pb2 as plugin_pb2
except:
sys.stderr.write('''
********************************************************************
@@ -1070,7 +1071,6 @@ def main_plugin():
msvcrt.setmode(sys.stdin.fileno(), os.O_BINARY)
msvcrt.setmode(sys.stdout.fileno(), os.O_BINARY)
- import proto.plugin_pb2 as plugin_pb2
data = sys.stdin.read()
request = plugin_pb2.CodeGeneratorRequest.FromString(data)