2
0
mirror of https://github.com/NixOS/nixpkgs.git synced 2024-12-13 01:03:25 +00:00

kinit: increase environment limit

Limit is already increased for standard xorg plasma distribution to
start, but with wayland, even more libraries being added

Increasing this limit to 1 << 20 (1M) seems to be enough (For me
length is 80K), and not so much for regular desktops

Signed-off-by: Yaroslav Bolyukin <iam@lach.pw>
This commit is contained in:
Yaroslav Bolyukin 2020-12-23 17:45:03 +03:00
parent e7659b6288
commit 0fbd3e9591
No known key found for this signature in database
GPG Key ID: 40B5D6948143175F

View File

@ -17,7 +17,7 @@ index f2db3e9..4ff2602 100644
if (read(0, &len, sizeof(unsigned)) == sizeof(unsigned)
- && len && len < (1 << 12)) {
+ && len) {
+ if (len >= (1 << 14)) {
+ if (len >= (1 << 20)) {
+ fprintf(stderr, "%s: exceeded environment length limit", argv[0]);
+ return 1;
+ }