mirror of
git://git.sv.gnu.org/coreutils.git
synced 2026-03-09 06:24:24 +02:00
(setusershell): Use rewind rather than
fseek/fseeko, to avoid configuration hassles with fseeko. Don't bother opening SHELLS_FILE if shellstream is NULL; it's not necessary.
This commit is contained in:
@@ -100,16 +100,8 @@ void
|
||||
setusershell ()
|
||||
{
|
||||
default_index = 0;
|
||||
if (shellstream == NULL)
|
||||
shellstream = fopen (SHELLS_FILE, "r");
|
||||
else
|
||||
{
|
||||
#ifdef HAVE_FSEEKO
|
||||
fseeko (shellstream, 0, 0);
|
||||
#else
|
||||
fseek (shellstream, 0L, 0);
|
||||
#endif
|
||||
}
|
||||
if (shellstream)
|
||||
rewind (shellstream);
|
||||
}
|
||||
|
||||
/* Close the shells file. */
|
||||
|
||||
Reference in New Issue
Block a user