default:
snprintf(errortext, sizeof errortext, "variable %s: numeric type needed"
,name);
- mmerror(ET_ERROR, errortext);
+ mmerror(PARSE_ERROR, ET_ERROR, errortext);
break;
}
}
}
}
snprintf(errortext, sizeof errortext, "unknown descriptor %s", name);
- mmerror(ET_NOTICE, errortext);
+ mmerror(PARSE_ERROR, ET_NOTICE, errortext);
}
struct descriptor
}
}
snprintf(errortext, sizeof errortext, "unknown descriptor %s", name);
- mmerror(ET_NOTICE, errortext);
+ mmerror(PARSE_ERROR, ET_NOTICE, errortext);
return NULL;
}
else
{
snprintf(errortext, sizeof errortext, "unknown descriptor header item '%d'", results->value);
- mmerror(ET_NOTICE, errortext);
+ mmerror(PARSE_ERROR, ET_NOTICE, errortext);
}
}
switch (results->value)
{
case ECPGd_nullable:
- mmerror(ET_NOTICE, "nullable is always 1");
+ mmerror(PARSE_ERROR, ET_NOTICE, "nullable is always 1");
break;
case ECPGd_key_member:
- mmerror(ET_NOTICE, "key_member is always 0");
+ mmerror(PARSE_ERROR, ET_NOTICE, "key_member is always 0");
break;
default:
break;
if (p->type->typ != ECPGt_array)
{
sprintf(errortext, "variable %s is not a pointer", name);
- mmerror(ET_FATAL, errortext);
+ mmerror(PARSE_ERROR, ET_FATAL, errortext);
}
if (p->type->u.element->typ != ECPGt_struct && p->type->u.element->typ != ECPGt_union)
{
sprintf(errortext, "variable %s is not a pointer to a structure or a union", name);
- mmerror(ET_FATAL, errortext);
+ mmerror(PARSE_ERROR, ET_FATAL, errortext);
}
/* restore the name, we will need it later on */
if (p->type->typ != ECPGt_struct && p->type->typ != ECPGt_union)
{
sprintf(errortext, "variable %s is neither a structure nor a union", name);
- mmerror(ET_FATAL, errortext);
+ mmerror(PARSE_ERROR, ET_FATAL, errortext);
}
/* restore the name, we will need it later on */
if (p == NULL)
{
sprintf(errortext, "The variable %s is not declared", name);
- mmerror(ET_FATAL, errortext);
+ mmerror(PARSE_ERROR, ET_FATAL, errortext);
}
return (p);
check_indicator(var->u.element);
break;
default:
- mmerror(ET_ERROR, "indicator variable must be integer type");
+ mmerror(PARSE_ERROR, ET_ERROR, "indicator variable must be integer type");
break;
}
}
if (!this)
{
sprintf(errortext, "invalid datatype '%s'", name);
- mmerror(ET_FATAL, errortext);
+ mmerror(PARSE_ERROR, ET_FATAL, errortext);
}
return (this);
if (type_index >= 0)
{
if (*length >= 0)
- mmerror(ET_FATAL, "No multi-dimensional array support");
+ mmerror(PARSE_ERROR, ET_FATAL, "No multi-dimensional array support");
*length = type_index;
}
if (type_dimension >= 0)
{
if (*dimension >= 0 && *length >= 0)
- mmerror(ET_FATAL, "No multi-dimensional array support");
+ mmerror(PARSE_ERROR, ET_FATAL, "No multi-dimensional array support");
if (*dimension >= 0)
*length = *dimension;
if (pointer_len>2)
{ sprintf(errortext, "No multilevel (more than 2) pointer supported %d",pointer_len);
- mmerror(ET_FATAL, errortext);
-/* mmerror(ET_FATAL, "No multilevel (more than 2) pointer supported %d",pointer_len);*/
+ mmerror(PARSE_ERROR, ET_FATAL, errortext);
+/* mmerror(PARSE_ERROR, ET_FATAL, "No multilevel (more than 2) pointer supported %d",pointer_len);*/
}
if (pointer_len>1 && type_enum!=ECPGt_char && type_enum!=ECPGt_unsigned_char)
- mmerror(ET_FATAL, "No pointer to pointer supported for this type");
+ mmerror(PARSE_ERROR, ET_FATAL, "No pointer to pointer supported for this type");
if (pointer_len>1 && (*length >= 0 || *dimension >= 0))
- mmerror(ET_FATAL, "No multi-dimensional array support");
+ mmerror(PARSE_ERROR, ET_FATAL, "No multi-dimensional array support");
if (*length >= 0 && *dimension >= 0 && pointer_len)
- mmerror(ET_FATAL, "No multi-dimensional array support");
+ mmerror(PARSE_ERROR, ET_FATAL, "No multi-dimensional array support");
switch (type_enum)
{
}
if (*length >= 0)
- mmerror(ET_FATAL, "No multi-dimensional array support for structures");
+ mmerror(PARSE_ERROR, ET_FATAL, "No multi-dimensional array support for structures");
break;
case ECPGt_varchar:
}
if (*length >= 0)
- mmerror(ET_FATAL, "No multi-dimensional array support for simple data types");
+ mmerror(PARSE_ERROR, ET_FATAL, "No multi-dimensional array support for simple data types");
break;
}