*** empty log message ***
authorClaus Gittinger <cg@exept.de>
Tue, 09 Nov 2004 18:30:22 +0100
changeset 1486 61ee314126a5
parent 1485 d8578cf3504b
child 1487 b243952bd3f1
*** empty log message ***
Socket.st
--- a/Socket.st	Tue Nov 09 18:28:58 2004 +0100
+++ b/Socket.st	Tue Nov 09 18:30:22 2004 +0100
@@ -2378,6 +2378,14 @@
     __INST(buffered) = false;
 # endif
 
+# if 0
+    // The original code was:
+    __INST(filePointer) = __MKOBJ((INT)fp); __STORESELF(filePointer);
+    // but for that, gcc generates wrong code, which loads self (volatile) into
+    // a register (bp), then calls __MKOBJ, then stores indirect bp.
+    // That is wrong if a scavenge occurs in MKOBJ, as bp is now still pointing to the old
+    // object.
+# endif
     {
 	OBJ t;
 
@@ -2913,6 +2921,14 @@
 		fprintf(stderr, "fdopen [Socket] -> %x\n", fp);
 	    }
 
+# if 0
+	    // The original code was:
+	    __INST(filePointer) = __MKOBJ((INT)fp); __STORESELF(filePointer);
+	    // but for that, gcc generates wrong code, which loads self (volatile) into
+	    // a register (bp), then calls __MKOBJ, then stores indirect bp.
+	    // That is wrong if a scavenge occurs in MKOBJ, as bp is now still pointing to the old
+	    // object.
+# endif
 	    {
 		OBJ t;
 
@@ -3157,5 +3173,5 @@
 !Socket class methodsFor:'documentation'!
 
 version
-    ^ '$Header: /cvs/stx/stx/libbasic2/Socket.st,v 1.201 2004-11-09 17:28:58 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libbasic2/Socket.st,v 1.202 2004-11-09 17:30:22 cg Exp $'
 ! !