X-Git-Url: http://git.tdb.fi/?p=gldbg.git;a=blobdiff_plain;f=source%2Fgldecoder.funcs.t;h=e02c1e815277fca0833a47489ff0aff3e5fe0e74;hp=152b71b5155aef93a253215d9a87251a81948e87;hb=151c65f1157f3b55d0b794db788b557bbc50ed0c;hpb=0be9f22fa27bfca77f494489fce0e62b66882e5b diff --git a/source/gldecoder.funcs.t b/source/gldecoder.funcs.t index 152b71b..e02c1e8 100644 --- a/source/gldecoder.funcs.t +++ b/source/gldecoder.funcs.t @@ -1,5 +1,5 @@ # $Id$ -wl('static unsigned decode_%s(GlDecoder *dec, const char *data)', func.name) +wl('static unsigned decode_%s(GlDecoder *dec, const char *data __attribute__((unused)))', func.name) wl('{') wl(' unsigned pos = 0;') if ret.ctype!="void": @@ -7,10 +7,10 @@ if ret.ctype!="void": for p in params: wl(' %s p_%s;', p.ctype, p.name) if ret.ctype!="void": - wl(' pos += read_%s(&ret, data+pos);', ret.io[0]) + wl(' pos += read_%s((%s *)&ret, data+pos);', ret.io[0].replace(' ', '_'), ret.io[0]) for p in params: if p.kind=="value": - wl(' pos += read_%s(&p_%s, data+pos);', p.io[0], p.name) + wl(' pos += read_%s((%s *)&p_%s, data+pos);', p.io[0].replace(' ', '_'), 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: