Commit 38732dba authored by Richard M. Stallman's avatar Richard M. Stallman

(main): Test HAVE_GETCWD rather than BSD_SYSTEM.

parent c4ea99e1
......@@ -418,19 +418,19 @@ main (argc, argv)
fail (argc, argv);
}
#ifdef BSD_SYSTEM
cwd = getwd (string);
#else
#ifdef HAVE_GETCWD
cwd = getcwd (string, sizeof string);
#else
cwd = getwd (string);
#endif
if (cwd == 0)
{
/* getwd puts message in STRING if it fails. */
fprintf (stderr, "%s: %s (%s)\n", argv[0],
#ifdef BSD_SYSTEM
string,
#else
#ifdef HAVE_GETCWD
"Cannot get current working directory",
#else
string,
#endif
strerror (errno));
fail (argc, argv);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment