Code Review
/
apps
/
low-level-can-service.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
review
|
tree
raw
|
patch
| inline |
side by side
(parent:
d0299d8
)
Fix compilation error with generated initializers for repeated pointer fields
author
Petteri Aimonen
<jpa@git.mail.kapsi.fi>
Sun, 7 Sep 2014 16:49:00 +0000
(19:49 +0300)
committer
Petteri Aimonen
<jpa@git.mail.kapsi.fi>
Sun, 7 Sep 2014 16:49:00 +0000
(19:49 +0300)
generator/nanopb_generator.py
patch
|
blob
|
history
diff --git
a/generator/nanopb_generator.py
b/generator/nanopb_generator.py
index
56dfdb0
..
9ffed03
100755
(executable)
--- a/
generator/nanopb_generator.py
+++ b/
generator/nanopb_generator.py
@@
-596,6
+596,8
@@
class Message:
else:
parts.append(field.get_initializer(null_init))
elif field.allocation == 'POINTER':
+ if field.rules == 'REPEATED':
+ parts.append('0')
parts.append('NULL')
elif field.allocation == 'CALLBACK':
if field.pbtype == 'EXTENSION':