xwayland: use explicit indexes when initializing atom_map

It's very easy to break the mapping between the atom_name enum and the
atom_map array. Use explicit indexes to prevent issues.
This commit is contained in:
Simon Ser 2020-03-06 12:29:20 +01:00 committed by Drew DeVault
parent 52c67284e2
commit 68a69ee079
2 changed files with 63 additions and 63 deletions

View file

@ -81,7 +81,7 @@ enum atom_name {
DND_ACTION_ASK,
DND_ACTION_PRIVATE,
_NET_CLIENT_LIST,
ATOM_LAST,
ATOM_LAST // keep last
};
extern const char *atom_map[ATOM_LAST];