| Summary: | work with empty /proc | ||
|---|---|---|---|
| Product: | Sisyphus | Reporter: | imz <vanyaz> |
| Component: | hasher | Assignee: | Dmitry V. Levin <ldv> |
| Status: | CLOSED FIXED | QA Contact: | |
| Severity: | enhancement | ||
| Priority: | P5 | CC: | at, glebfm, ldv, placeholder |
| Version: | unstable | ||
| Hardware: | all | ||
| OS: | Linux | ||
Thanks, fixed in upcoming release (0.5-alt1). Thanks, fixed in upcoming release (0.5-alt1). |
/usr/share/hasher/initroot terminates too early when /proc is empty. This patch makes it work: --- initroot.orig 2003-07-30 18:24:24 +0400 +++ initroot 2003-08-20 12:08:44 +0400 @@ -107,7 +107,7 @@ gid2=\"$(echo \"$ugid2\" |cut -d: -f2)\" [ -n \"$nprocs\" ] || - nprocs=\"$(N=`egrep -cs ^cpu[0-9]+ /proc/stat`; [ \"$N\" -gt 0 ] 2>/dev/null && echo -n \"$N\" || echo 1)\" + nprocs=\"$(N=`egrep -cs ^cpu[0-9]+ /proc/stat ||:`; [ \"$N\" -gt 0 ] 2>/dev/null && echo -n \"$N\" || echo 1)\" filelist=\"$(print_uris setup filesystem rpm \'fakeroot>=0:0.7.3\')\" || Fatal \"failed to generate initial package file list.\" --- --- hasher-0.4-alt1