diff --git a/python_modules/ptypes.py b/python_modules/ptypes.py index 631739e..916ba50 100644 --- a/python_modules/ptypes.py +++ b/python_modules/ptypes.py @@ -1055,6 +1055,8 @@ class ChannelType(Type): m.value = info.count info.count = m.value + 1 info.messages.append(m) + if m.name in info.messages_byname: + raise Exception("Duplicated message name '%s' in channel '%s'" % (m.name, self.name)) info.messages_byname[m.name] = m self.server_messages = server_info.messages