summaryrefslogtreecommitdiffstats
path: root/generator/nanopb_generator.py
diff options
context:
space:
mode:
authorPetteri Aimonen <jpa@git.mail.kapsi.fi>2015-01-27 17:47:25 +0200
committerPetteri Aimonen <jpa@git.mail.kapsi.fi>2015-01-27 17:47:25 +0200
commit25b92c5b4e154130bf0787009046ea60175d28e8 (patch)
tree6f562ae78961010f61d936f805deb14df690c0c1 /generator/nanopb_generator.py
parent5aa8207ab1acf3b614b528b3d84e60d9266d35ae (diff)
Fix generator bug when oneof is first field in a message.
Added test case for the same. Update issue 142 Status: FixedInGit
Diffstat (limited to 'generator/nanopb_generator.py')
-rwxr-xr-xgenerator/nanopb_generator.py1
1 files changed, 0 insertions, 1 deletions
diff --git a/generator/nanopb_generator.py b/generator/nanopb_generator.py
index 520824ce..4c01502c 100755
--- a/generator/nanopb_generator.py
+++ b/generator/nanopb_generator.py
@@ -633,7 +633,6 @@ class OneOf(Field):
return '\n'.join([f.tags() for f in self.fields])
def pb_field_t(self, prev_field_name):
- prev_field_name = prev_field_name or self.name
result = ',\n'.join([f.pb_field_t(prev_field_name) for f in self.fields])
return result