Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 833342 - savedconfig.eclass: test (eclass/test/savedconfig.sh) runs "rm -rf /*" when ED is not set
Summary: savedconfig.eclass: test (eclass/test/savedconfig.sh) runs "rm -rf /*" when E...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Eclasses (show other bugs)
Hardware: All Linux
: Normal critical (vote)
Assignee: Gentoo's Team for Core System packages
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-02-14 15:31 UTC by Anna Vyalkova
Modified: 2022-02-14 21:49 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Anna Vyalkova 2022-02-14 15:31:47 UTC
Please change ${ED} to ${ED?} so it dies instead of removing system root.

Steps to Reproduce:
1. Don't read savedconfig.sh (who reads scripts before trying to execute them,
   what can go wrong?)
2. Know nothing about eclass tests
3. Run "bash test/savedconfig.sh"

Actual Result:
Tries to remove system root.

Expected Result:
Dies.
Comment 1 Larry the Git Cow gentoo-dev 2022-02-14 17:25:05 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=318f4a2e9b59083194ac34389a1ca29fce3c969b

commit 318f4a2e9b59083194ac34389a1ca29fce3c969b
Author:     Mike Gilbert <floppym@gentoo.org>
AuthorDate: 2022-02-14 17:20:39 +0000
Commit:     Mike Gilbert <floppym@gentoo.org>
CommitDate: 2022-02-14 17:24:57 +0000

    eclass/tests/savedconfig.sh: abort when source tests-common.sh fails
    
    Closes: https://bugs.gentoo.org/833342
    Signed-off-by: Mike Gilbert <floppym@gentoo.org>

 eclass/tests/savedconfig.sh | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)