dbus: move DBUS_IS_DIR_SEPARATOR to dbus-internals.h

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
This commit is contained in:
Marc-André Lureau 2022-02-09 11:52:51 +04:00 committed by Simon McVittie
parent d98c98d1e5
commit dcdb992dd2
2 changed files with 10 additions and 12 deletions

View file

@ -334,18 +334,7 @@ _dbus_verbose_init (void)
}
}
/** @def DBUS_IS_DIR_SEPARATOR(c)
* macro for checking if character c is a patch separator
*
* @todo move to a header file so that others can use this too
*/
#ifdef DBUS_WIN
#define DBUS_IS_DIR_SEPARATOR(c) (c == '\\' || c == '/')
#else
#define DBUS_IS_DIR_SEPARATOR(c) (c == '/')
#endif
/**
/**
remove source root from file path
the source root is determined by
*/

View file

@ -488,6 +488,15 @@ dbus_bool_t _dbus_get_local_machine_uuid_encoded (DBusString *uuid_str,
# define _DBUS_END_IGNORE_LEAKS do { } while (0)
#endif
/** @def DBUS_IS_DIR_SEPARATOR(c)
* macro for checking if character c is a path separator
*/
#ifdef DBUS_WIN
#define DBUS_IS_DIR_SEPARATOR(c) (c == '\\' || c == '/')
#else
#define DBUS_IS_DIR_SEPARATOR(c) (c == '/')
#endif
DBUS_END_DECLS
#endif /* DBUS_INTERNALS_H */