[PR #3325] [CLOSED] WIP: improve firejail's error messaging #4722

Closed
opened 2026-05-05 10:25:24 -06:00 by gitea-mirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/netblue30/firejail/pull/3325
Author: @ghost
Created: 4/7/2020
Status: Closed

Base: masterHead: error-clarity


📝 Commits (1)

  • 60ad13f slightly improve firejail's error messages

📊 Changes

1 file changed (+126 additions, -126 deletions)

View changed files

📝 src/firejail/main.c (+126 -126)

📄 Description

One of those days on a rolling release OS. Both kernel and systemd just got upgraded, together with a few dozen other packages. After a reboot frustration levels upped as my main dev machine was only barely alive. After taking a long outdoor reflective breather I started to rebuild a few mission-critical packages. Error: too many environment variables. Exit. No sender. No return address. No nothing.

This strangely mixed crystal clear and utterly cryptic message had apparently started to pop-up left and right. Sure, I use plenty of these env vars (134 according to env), but never had I been told I use too many :) After more digging it turned out I had been bitten by a newly introduced sane maximum number of environment variables. Going over the commit in question rapidly improved my mood. At last I had found something I could relate to: didn't pass the 'sanity check' :) Took care of upping the number to accomodate my 134 vars in my firejail-git PKGBUILD.

Nothing wrong with setting a limit, nor with drawing the line at 100. In fact probably a very wise thing to do as a sandbox application. All sarcasm aside, a slightly more contextual indication of the originator of the error message(s) would have helped. This WIP is a minimalistic first attempt to do just that, nothing more, nothing less. For now it only touched error messages directly followed by exit(1) that didn't already mention {F,f}irejail in the error text. I did notice the errExit("foo") defined in common.h but decided to not touch that yet and await comments/suggestions.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/netblue30/firejail/pull/3325 **Author:** [@ghost](https://github.com/ghost) **Created:** 4/7/2020 **Status:** ❌ Closed **Base:** `master` ← **Head:** `error-clarity` --- ### 📝 Commits (1) - [`60ad13f`](https://github.com/netblue30/firejail/commit/60ad13f21fd7f90b1a4ae2c04434a27846537f08) slightly improve firejail's error messages ### 📊 Changes **1 file changed** (+126 additions, -126 deletions) <details> <summary>View changed files</summary> 📝 `src/firejail/main.c` (+126 -126) </details> ### 📄 Description One of those days on a rolling release OS. Both kernel and systemd just got upgraded, together with a few dozen other packages. After a reboot frustration levels upped as my main dev machine was only barely alive. After taking a long outdoor reflective breather I started to rebuild a few mission-critical packages. `Error: too many environment variables`. Exit. No sender. No return address. No nothing. This strangely mixed crystal clear and utterly cryptic message had apparently started to pop-up left and right. Sure, I use plenty of these env vars (134 according to `env`), but never had I been told I use too many :) After more digging it turned out I had been bitten by a newly introduced _sane maximum number of environment variables_. Going over the [commit in question](https://github.com/netblue30/firejail/commit/88258569cb5f455dd39447867e559bfba20d91c7) rapidly improved my mood. At last I had found something I could relate to: didn't pass the 'sanity check' :) Took care of upping the number to accomodate my 134 vars in my firejail-git PKGBUILD. Nothing wrong with setting a limit, nor with drawing the line at 100. In fact probably a very wise thing to do as a sandbox application. All sarcasm aside, a slightly more contextual indication of the originator of the error message(s) would have helped. This WIP is a minimalistic first attempt to do just that, nothing more, nothing less. For now it only touched error messages directly followed by exit(1) that didn't already mention {F,f}irejail in the error text. I did notice the errExit("foo") defined in [common.h](https://github.com/netblue30/firejail/blob/master/src/include/common.h#L35) but decided to not touch that yet and **await comments/suggestions**. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
gitea-mirror 2026-05-05 10:25:24 -06:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: github-starred/firejail#4722
No description provided.