Custom Query (1030 matches)
Results (499 - 501 of 1030)
| Ticket | Resolution | Summary | Owner | Reporter |
|---|---|---|---|---|
| #1331 | fixed | wrong results from probe-file/open on many symlinks | ||
| Description |
Hi, This is a very minor bug, but we ran into it in the context of a much larger system and it took awhile to figure out what was going on. This is on CCL 1.11-dev-r16394M-trunk on a Linux 2.6.32-431.el6.x86_64 system. Setup: Create a file and several levels of symlinks to it. The following will work for this in bash: echo "Hello World" > 0
for ((i=0;i < 30;i=i+1)) do ln -s $i $((i+1)) ; done
Once we get past enough symlinks, we find that CCL reports that the files do not exist: > (probe-file "8") #P"/home/users/jared/ccl-symlinks/0" ... > (probe-file "20") #P"/home/users/jared/ccl-symlinks/0" > (probe-file "21") NIL ;; Bug? Expected #P"/home/users/jared/ccl-symlinks/0" > (probe-file "22") NIL ;; Bug? Expected #P"/home/users/jared/ccl-symlinks/0" We also run into problems when trying to open these files. For instance: (defun my-read (filename)
(with-open-file (stream filename :direction :input)
(read-line stream)))
> (my-read "8")
"Hello World"
NIL
> (my-read "20")
"Hello World"
NIL
(my-read "21") ;; Bug? The file does exist...
> Error: No such file or directory : "21"
> While executing: CCL::MAKE-FILE-STREAM, in process listener(1).
> Type :POP to abort, :R for a list of available restarts.
> Type :? for other options.
From poking around, it seems like this may be due to the way that #_REALPATH is used in the implementation of %REALPATH, which is used by PROBE-FILE. It looks like the C realpath() function can return many kinds of error conditions, such as ELOOP, which don't necessarily mean that the file doesn't exist, but that the implementation of probe-file essentially just checks its return value without paying attention to the ERRNO. FWIW, it seems that SBCL can PROBE-FILE all of these files without a problem, but it too fails to open files from "9" and above. Fortunately it provides a good error message instead of saying that the file does not exist: error opening #P"/home/users/jared/ccl-symlinks/9":
Too many levels of symbolic links
Anyway this is all minor, but it would be nice if probe-file would either report that the file does indeed exist or give a "too many symlinks" error, and similarly it would be nice if opening the file either worked or produced a "too many symlinks" error instead of saying the file doesn't exist. Thanks! Jared |
|||
| #254 | fixed | define-method-combination does not recognize full set of argument lambda list keywords | ||
| Description |
Welcome to Clozure Common Lisp Version 1.2-r8591:8592MS (DarwinPPC32)!
? (define-method-combination standard+ ()
((around (:around))
(before (:before))
(primary () :required t)
(after (:after)))
(:arguments &optional args)
(flet ((call-methods (methods)
(mapcar #'(lambda (method)
`(call-method ,method))
methods)))
(let ((form (if (or before after (rest primary))
`(multiple-value-prog1
(progn ,@(call-methods before)
(call-method ,(first primary)
,(rest primary)))
,@(call-methods (reverse after)))
`(call-method ,(first primary)))))
`(progn (print ,args)
,(if around
`(call-method ,(first around)
(,@(rest around)
(make-method ,form)))
form)))))
;Compiler warnings :
; Unused lexical variable &OPTIONAL, in an anonymous lambda form
STANDARD+
?
|
|||
| #315 | fixed | #'<macro op> in a :method clause causes spurious signature incongruity | ||
| Description |
QRES-GDS> (lisp-implementation-version) "Version 1.2-r9777-working-0711 (LinuxX8664)" QRES-GDS> (defgeneric test-or (a)
#<STANDARD-GENERIC-FUNCTION TEST-OR #x30006EF2F15F> QRES-GDS> (defgeneric test-or (a)
;Compiler warnings : ; In (TEST-OR (SEQUENCE)) inside an anonymous lambda form: FUNCTION can't be used to reference lexically visible macro OR. ; Evaluation aborted. ;;; the slime backtrace buffer contained: Lambda list of method #<STANDARD-METHOD TEST-OR (SEQUENCE)> is incompatible with that of the generic function TEST-OR. Method's lambda-list : (A) Generic-function's : (A)
Restarts:
Backtrace:
... |
|||
