On Sun 13 Apr 2008 at 08:46AM, Mike Gerdts wrote:
> As I was looking into why "pkg contents" did not work as non-root[1],
> I noticed that /var/pkg/pkg/*/installed files do not end with a
> newline character. While the code that is supposed to read and modify
> these files handles it just fine, I suspect that it will become
> problematic in the real world because:
Mike, I think it's just an oversight; I filed bug 1164 on your behalf.
> - Sysadmins have a habit of using the wrong tool for the job because
> the right tool often times doesn't exist or is undocumented/private.
> - It is easy to miss the fact that the newline is missing when looking
> at the file.
> - Sun's version of sed has not historically handled files that are
> missing the final newline gracefully.
> - The default mode of vi/vim will add a newline at the end.
> - In the event that such a file gets corrupted, it makes it harder for
> support to help a sysadmin fix the file.
I think our hope is that pkg(5) can be largely self-repairing. I
cringe to think of an admin manually tweaking this stuff, but I
know it will happen.
-dp
--
Daniel Price - Solaris Kernel Engineering - [EMAIL PROTECTED] - blogs.sun.com/dp
_______________________________________________
pkg-discuss mailing list
[email protected]
http://mail.opensolaris.org/mailman/listinfo/pkg-discuss