Generate headers for encode and decode functions.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@866 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
@@ -329,6 +329,10 @@ encode_type (char *name, Type *t)
|
|||||||
static void
|
static void
|
||||||
generate_type_encode (Symbol *s)
|
generate_type_encode (Symbol *s)
|
||||||
{
|
{
|
||||||
|
fprintf (headerfile,
|
||||||
|
"int encode_%s(unsigned char *, int, void *);\n",
|
||||||
|
s->gen_name);
|
||||||
|
|
||||||
fprintf (codefile, "int\n"
|
fprintf (codefile, "int\n"
|
||||||
"encode_%s(unsigned char *p, int len, void *d)\n"
|
"encode_%s(unsigned char *p, int len, void *d)\n"
|
||||||
"{\n"
|
"{\n"
|
||||||
@@ -541,6 +545,10 @@ decode_type (char *name, Type *t)
|
|||||||
static void
|
static void
|
||||||
generate_type_decode (Symbol *s)
|
generate_type_decode (Symbol *s)
|
||||||
{
|
{
|
||||||
|
fprintf (headerfile,
|
||||||
|
"int decode_%s(unsigned char *, int, void *);\n",
|
||||||
|
s->gen_name);
|
||||||
|
|
||||||
fprintf (codefile, "int\n"
|
fprintf (codefile, "int\n"
|
||||||
"decode_%s(unsigned char *p, int len, void *d)\n"
|
"decode_%s(unsigned char *p, int len, void *d)\n"
|
||||||
"{\n"
|
"{\n"
|
||||||
|
@@ -329,6 +329,10 @@ encode_type (char *name, Type *t)
|
|||||||
static void
|
static void
|
||||||
generate_type_encode (Symbol *s)
|
generate_type_encode (Symbol *s)
|
||||||
{
|
{
|
||||||
|
fprintf (headerfile,
|
||||||
|
"int encode_%s(unsigned char *, int, void *);\n",
|
||||||
|
s->gen_name);
|
||||||
|
|
||||||
fprintf (codefile, "int\n"
|
fprintf (codefile, "int\n"
|
||||||
"encode_%s(unsigned char *p, int len, void *d)\n"
|
"encode_%s(unsigned char *p, int len, void *d)\n"
|
||||||
"{\n"
|
"{\n"
|
||||||
@@ -541,6 +545,10 @@ decode_type (char *name, Type *t)
|
|||||||
static void
|
static void
|
||||||
generate_type_decode (Symbol *s)
|
generate_type_decode (Symbol *s)
|
||||||
{
|
{
|
||||||
|
fprintf (headerfile,
|
||||||
|
"int decode_%s(unsigned char *, int, void *);\n",
|
||||||
|
s->gen_name);
|
||||||
|
|
||||||
fprintf (codefile, "int\n"
|
fprintf (codefile, "int\n"
|
||||||
"decode_%s(unsigned char *p, int len, void *d)\n"
|
"decode_%s(unsigned char *p, int len, void *d)\n"
|
||||||
"{\n"
|
"{\n"
|
||||||
|
Reference in New Issue
Block a user