/*
- * Copyright (c) 1995-1999, Index Data
+ * Copyright (c) 1995-2002, Index Data
* See the file LICENSE for details.
* Sebastian Hammer, Adam Dickmeiss
*
* $Log: odr_choice.c,v $
- * Revision 1.17 1999-11-30 13:47:11 adam
+ * Revision 1.19 2002-02-20 14:42:30 adam
+ * Fixed BER decoding of OPTIONAL CHOICE
+ *
+ * Revision 1.18 2000/02/29 13:44:55 adam
+ * Check for config.h (currently not generated).
+ *
+ * Revision 1.17 1999/11/30 13:47:11 adam
* Improved installation. Moved header files to include/yaz.
*
* Revision 1.16 1999/04/20 09:56:48 adam
* A damn mess, but now things work, I think.
*
*/
+#if HAVE_CONFIG_H
+#include <config.h>
+#endif
#include <yaz/odr.h>
return 0;
if (o->direction != ODR_DECODE && !*(char**)p)
return 0;
+
+ if (o->direction == ODR_DECODE)
+ {
+ *which = -1;
+ *(char**)p = 0;
+ }
o->choice_bias = -1;
if (o->direction == ODR_PRINT)
return 1;
}
}
- *which = -1;
- *(char*)p = 0;
return 0;
}