[PR #371] [MERGED] fs_etc: continue to copy files if one fails. #3606

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

📋 Pull Request Information

Original PR: https://github.com/netblue30/firejail/pull/371
Author: @fbarriga
Created: 3/20/2016
Status: Merged
Merged: 3/21/2016
Merged by: @netblue30

Base: masterHead: fbarriga/etc_copy_error


📝 Commits (1)

  • 5f43f3c fs_etc: continue to copy files if one fails.

📊 Changes

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

View changed files

📝 src/firejail/fs_etc.c (+2 -1)

📄 Description

Currently if one file fails when copying private-etc files the process stop and doesn't copy the other files. Also it doesn't log which file failed.

Example:

private-etc localtime,foo,resolv.conf

Before:

only copied localtime

log

/run/firejail/mnt/cp: failed to restore the default file creation context: No such file or directory

Now:

copy localtime and resolv.conf

log:

Warning (fs_etc): error copying file /etc/foo, skipping...

🔄 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/371 **Author:** [@fbarriga](https://github.com/fbarriga) **Created:** 3/20/2016 **Status:** ✅ Merged **Merged:** 3/21/2016 **Merged by:** [@netblue30](https://github.com/netblue30) **Base:** `master` ← **Head:** `fbarriga/etc_copy_error` --- ### 📝 Commits (1) - [`5f43f3c`](https://github.com/netblue30/firejail/commit/5f43f3c73fc61b46b39dfdd41e2b5418fdba2f7b) fs_etc: continue to copy files if one fails. ### 📊 Changes **1 file changed** (+2 additions, -1 deletions) <details> <summary>View changed files</summary> 📝 `src/firejail/fs_etc.c` (+2 -1) </details> ### 📄 Description Currently if one file fails when copying private-etc files the process stop and doesn't copy the other files. Also it doesn't log which file failed. # Example: ``` private-etc localtime,foo,resolv.conf ``` # Before: only copied `localtime` ## log ``` /run/firejail/mnt/cp: failed to restore the default file creation context: No such file or directory ``` # Now: copy `localtime` and `resolv.conf` ## log: ``` Warning (fs_etc): error copying file /etc/foo, skipping... ``` --- <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:04:30 -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#3606
No description provided.