diff --git a/CHANGELOG b/CHANGELOG index d0a80933f..63fd88a38 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -57,6 +57,10 @@ appropraite documentation section (new-doc). Function was obfuscated with ifdefs with non-even pairs of =#\{= and =#\}=. ** Issues fixed +- ext:file-stream-fd +Doesn't cause an internal-error if fed with not a file-stream (signals a +SIMPLE-TYPE-ERROR condtition). + - stable-sort bugfix and improvement in speed Adapted from SBCL by Diogo Franco. diff --git a/src/c/file.d b/src/c/file.d index 7e9fd652e..fca767c34 100755 --- a/src/c/file.d +++ b/src/c/file.d @@ -4201,8 +4201,9 @@ si_file_stream_fd(cl_object s) { cl_object ret; - unlikely_if (!ECL_ANSI_STREAM_P(s)) - FEerror("file_stream_fd: not a stream", 0); + unlikely_if (!ECL_FILE_STREAM_P(s)) { + not_a_file_stream(s); + } switch ((enum ecl_smmode)s->stream.mode) { case ecl_smm_input: @@ -4218,7 +4219,7 @@ si_file_stream_fd(cl_object s) default: ecl_internal_error("not a file stream"); } - @(return ret);; + @(return ret); } /**********************************************************************