diff --git a/src/ChangeLog b/src/ChangeLog index 1cda4ebb7..2870e0b3a 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,8 @@ +2005-04-14 Roland Illig + + * util.h (str_unconst): Added a conditional INLINE_STR_UNCONST + that makes str_unconst() an inline function. + 2005-04-14 Roland Illig * view.c (struct WView): Removed the view_active field. It was diff --git a/src/util.h b/src/util.h index 757462320..464d484db 100644 --- a/src/util.h +++ b/src/util.h @@ -7,7 +7,15 @@ * intended to pass strings to legacy libraries that don't know yet * about the "const" modifier. The return value of this function * MUST NOT be modified. */ +#ifdef INLINE_STR_UNCONST +static char *str_unconst_inlined (const char *s) +{ + return (char *) s; +} +#define str_unconst(s) str_unconst_inlined(s) +#else extern char *str_unconst (const char *); +#endif /* String managing functions */