]> git.tdb.fi Git - gldbg.git/blobdiff - source/gldecoder.funcs.t
Print the contents of arrays and references
[gldbg.git] / source / gldecoder.funcs.t
index 055a272ae3e60c60c51d7fa84ba8c58060108bd4..152b71b5155aef93a253215d9a87251a81948e87 100644 (file)
@@ -1,7 +1,4 @@
 # $Id$
-^typemap gl.tm
-^iomap gl.io
-^spec gl gl.spec
 wl('static unsigned decode_%s(GlDecoder *dec, const char *data)', func.name)
 wl('{')
 wl('   unsigned pos = 0;')
@@ -14,6 +11,8 @@ if ret.ctype!="void":
 for p in params:
        if p.kind=="value":
                wl('    pos += read_%s(&p_%s, data+pos);', p.io[0], p.name)
+       elif p.kind=="array" and p.io and p.io[0]=="string":
+               wl('  pos += read_string_array(&p_%s, data+pos);', p.name)
        elif p.csize:
                wl('    pos += read_data((const void **)&p_%s, data+pos);', p.name)
        else:
@@ -27,7 +26,7 @@ for p in params:
 wl(');')
 wl('   return pos;')
 wl('}')
-:static int decode_func(GlDecoder *dec, short func, const char *data)
+:static int decode_func(GlDecoder *dec, unsigned short func, const char *data)
 :{
 :      switch(func)
 :      {