diff --git a/dix/dix_priv.h b/dix/dix_priv.h index 30c10ce2cf..a368b54c2c 100644 --- a/dix/dix_priv.h +++ b/dix/dix_priv.h @@ -704,6 +704,18 @@ static inline int WriteRpcbufToClient(ClientPtr pClient, return ret; } +/* + * @brief make atom from null-terminated string + * + * if atom already existing, return the existing Atom ID + * + * @param name the atom name + * @return atom ID + */ +static inline Atom dixAddAtom(const char *name) { + return MakeAtom(name, strlen(name), TRUE); +} + /* * @brief retrieve atom ID by name *