| Summary: | [PATCH] sysinstall can get SIGPIPE if a distr. file is broken | ||||||
|---|---|---|---|---|---|---|---|
| Product: | Base System | Reporter: | un1i <un1i> | ||||
| Component: | conf | Assignee: | jkh | ||||
| Status: | Closed FIXED | ||||||
| Severity: | Affects Only Me | ||||||
| Priority: | Normal | ||||||
| Version: | 4.0-CURRENT | ||||||
| Hardware: | Any | ||||||
| OS: | Any | ||||||
| Attachments: |
|
||||||
Responsible Changed From-To: freebsd-bugs->jkh 's see what Jordan has to say about this. :-) State Changed From-To: open->closed Agreed, fix adopted, thanks. |
Under certain circumstances (e.g., when fetching files in FTP ASCII mode from a server that does LF->CRLF substitution), distribution files can be damaged in such a way that gunzip or cpio stops. Sysinstall tries to write more data to it and therefore gets a SIGPIPE. Fix: I don't think it's necessary to handle this case differently from others that are already handled, so ignoring the signal is enough. But a hint for the user might be helpful (in dist.c and media.c). /usr/src/release#diff -ru sysinstall sysinstall.new How-To-Repeat: /tmp%mkdir compat20 ; cd compat20 /tmp/compat20%fetch ftp://ftp2.de.freebsd.org/pub/FreeBSD/releases/i386/3.3-RELEASE/compat20/compat20.aa /tmp/compat20%fetch ftp://ftp2.de.freebsd.org/pub/FreeBSD/releases/i386/3.3-RELEASE/compat20/compat20.ab /tmp/compat20%fetch ftp://ftp2.de.freebsd.org/pub/FreeBSD/releases/i386/3.3-RELEASE/compat20/compat20.inf /tmp/compat20%fetch ftp://ftp2.de.freebsd.org/pub/FreeBSD/releases/i386/3.3-RELEASE/compat20/compat20.mtree /tmp/compat20%mv compat20.aa x /tmp/compat20%sed -e 's/.*/&^M/' < x > compat20.aa # simulate damage Now use sysinstall to install this distribution from filesystem.