diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/fileio.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/fileio.c b/src/fileio.c index 71a07938b11..945b986f7fb 100644 --- a/src/fileio.c +++ b/src/fileio.c | |||
| @@ -2020,9 +2020,20 @@ before the error is signaled.") | |||
| 2020 | 2020 | ||
| 2021 | record_unwind_protect (close_file_unwind, make_number (fd)); | 2021 | record_unwind_protect (close_file_unwind, make_number (fd)); |
| 2022 | 2022 | ||
| 2023 | #ifdef S_IFSOCK | ||
| 2024 | /* This code will need to be changed in order to work on named | ||
| 2025 | pipes, and it's probably just not worth it. So we should at | ||
| 2026 | least signal an error. */ | ||
| 2027 | if ((st.st_mode & S_IFMT) == S_IFSOCK) | ||
| 2028 | Fsignal (Qfile_error, | ||
| 2029 | Fcons (build_string ("reading from named pipe"), | ||
| 2030 | Fcons (filename, Qnil))); | ||
| 2031 | #endif | ||
| 2032 | |||
| 2023 | /* Supposedly happens on VMS. */ | 2033 | /* Supposedly happens on VMS. */ |
| 2024 | if (st.st_size < 0) | 2034 | if (st.st_size < 0) |
| 2025 | error ("File size is negative"); | 2035 | error ("File size is negative"); |
| 2036 | |||
| 2026 | { | 2037 | { |
| 2027 | register Lisp_Object temp; | 2038 | register Lisp_Object temp; |
| 2028 | 2039 | ||