0.9.18.11: Remove unused (probably wrong) definition of malloc from sb-bsd-sockets
authorAndreas Fuchs <asf@boinkor.net>
Fri, 27 Oct 2006 21:44:42 +0000 (21:44 +0000)
committerAndreas Fuchs <asf@boinkor.net>
Fri, 27 Oct 2006 21:44:42 +0000 (21:44 +0000)
contrib/sb-bsd-sockets/malloc.lisp [deleted file]
contrib/sb-bsd-sockets/sb-bsd-sockets.asd

diff --git a/contrib/sb-bsd-sockets/malloc.lisp b/contrib/sb-bsd-sockets/malloc.lisp
deleted file mode 100644 (file)
index 0b6ca39..0000000
+++ /dev/null
@@ -1,16 +0,0 @@
-(in-package :sb-bsd-sockets-internal)
-
-(defun malloc (size)
-  "Allocate foreign memory in some way that allows the garbage collector to free it later.  Note that memory allocated this way does not count as `consed' for the purposes of deciding when to gc, so explicitly calling EXT:GC occasionally would be a good idea if you use it a lot"
-  ;; we can attach finalizers to any object, and they'll be called on
-  ;; the next gc after the object no longer has references.  We can't
-  ;; however make the finalizer close over the object, or it'll never
-  ;; have no references.  I experimentally determined that (sap-alien
-  ;; (alien-sap f)) is not EQ to f, so we can do it that way
-  (let* ((memory (make-alien (unsigned 8) size))
-         (alias (sap-alien (alien-sap memory)
-                                 (* (unsigned 8)))))
-    (sb-ext:finalize memory
-                     (lambda ()
-                       (free-alien alias)))))
-
index 7b2aaa1..eb49b66 100644 (file)
@@ -11,7 +11,6 @@
     #+sb-building-contrib "SYS:CONTRIB;SB-BSD-SOCKETS;"
     :components ((:file "defpackage")
                 (:file "split" :depends-on ("defpackage"))
-                (:file "malloc" :depends-on ("defpackage"))
                  #+win32
                 (:file "win32-lib")
                 #-win32 (sb-grovel:grovel-constants-file