diff options
author | 2021-12-01 05:55:48 -0300 | |
---|---|---|
committer | 2021-12-01 15:57:20 -0300 | |
commit | be5970c3d86e074abfcfc01c694b9b6c61eb6b9b (patch) | |
tree | 15b95731065db92f8898b51a36838002ae1b52be /src | |
parent | util.c: Rename nogroups to force_nogroups on drop_privs (diff) | |
download | firejail-be5970c3d86e074abfcfc01c694b9b6c61eb6b9b.tar.gz firejail-be5970c3d86e074abfcfc01c694b9b6c61eb6b9b.tar.zst firejail-be5970c3d86e074abfcfc01c694b9b6c61eb6b9b.zip |
Fix duplicated fwarning warnings
This amends commit 11418a46c ("dns fixes", 2019-10-31).
fwarning already prints "Warning: " at the beginning.
Kind of relates to commit 6ddedeba0 ("Make nogroups work on nvidia
again", 2021-11-29) / PR #4725, which removed code affected by this.
Command used to find the duplicates:
git grep -i -F 'fwarning("Warning:' -- src
Diffstat (limited to 'src')
-rw-r--r-- | src/firejail/main.c | 2 | ||||
-rw-r--r-- | src/firejail/profile.c | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/src/firejail/main.c b/src/firejail/main.c index 59e88bdc6..e8815d5cd 100644 --- a/src/firejail/main.c +++ b/src/firejail/main.c | |||
@@ -2642,7 +2642,7 @@ int main(int argc, char **argv, char **envp) { | |||
2642 | else if (cfg.dns4 == NULL) | 2642 | else if (cfg.dns4 == NULL) |
2643 | cfg.dns4 = dns; | 2643 | cfg.dns4 = dns; |
2644 | else { | 2644 | else { |
2645 | fwarning("Warning: up to 4 DNS servers can be specified, %s ignored\n", dns); | 2645 | fwarning("up to 4 DNS servers can be specified, %s ignored\n", dns); |
2646 | free(dns); | 2646 | free(dns); |
2647 | } | 2647 | } |
2648 | } | 2648 | } |
diff --git a/src/firejail/profile.c b/src/firejail/profile.c index 756b370aa..5e24591fa 100644 --- a/src/firejail/profile.c +++ b/src/firejail/profile.c | |||
@@ -1106,7 +1106,7 @@ int profile_check_line(char *ptr, int lineno, const char *fname) { | |||
1106 | else if (cfg.dns4 == NULL) | 1106 | else if (cfg.dns4 == NULL) |
1107 | cfg.dns4 = dns; | 1107 | cfg.dns4 = dns; |
1108 | else { | 1108 | else { |
1109 | fwarning("Warning: up to 4 DNS servers can be specified, %s ignored\n", dns); | 1109 | fwarning("up to 4 DNS servers can be specified, %s ignored\n", dns); |
1110 | free(dns); | 1110 | free(dns); |
1111 | } | 1111 | } |
1112 | return 0; | 1112 | return 0; |