Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow longer names (MAX_LAYER_NAME_LEN was 32, now 64) #574

Closed
wants to merge 2 commits into from

Conversation

rxhfcy
Copy link

@rxhfcy rxhfcy commented Sep 7, 2023

This trivial patch allows a little bit longer layer names (I think the maximum could easily be 128 or 256 but I chose to be very conservative to maximize the probability of you accepting the change).

The reasoning for allowing longer names is that it is conceivable that someone could try to use names more than 32 - 2 letters long (I already personally did that, wasn't even joking) (issue #558)

Furthermore, if someone uses their non-english native language with non-ASCII characters, 32 bytes is even more restrictive (32 bytes can hold even fewer than 32 longer-than-1-byte UTF-8 characters)

@rxhfcy rxhfcy mentioned this pull request Sep 7, 2023
@rxhfcy
Copy link
Author

rxhfcy commented Apr 7, 2024

@rvaiya Could you please consider accepting this trivial change that fixes a legitimate bug (#558)?

Reason: I legitimately (without irony or trying to be funny) tried to use a name that was exactly 1 character too long (33). Potentially other users would want to do that too, and keyd silently failing because of such a length is unreasonable.

Changing MAX_LAYER_NAME_LEN in src/config.h to even 64 instead of 32 would allow users to use slightly sillier names if they want to.

@rvaiya
Copy link
Owner

rvaiya commented Jul 27, 2024

This has landed in master.

@rvaiya rvaiya closed this Jul 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants