Bug 49769

GemStone/S 64 Bit

3.6.8, 3.6.7, 3.6.6, 3.6.5, 3.6.4, 3.6.3, 3.6.2, 3.6.1, 3.6, 3.5.8, 3.5.7, 3.5.6, 3.5.5, 3.5.4, 3.5.3, 3.5.2, 3.5.1, 3.5

3.7

Crash with thread-safe GCI, if C data lost due to FFI structures faulting out

It is possible for CByteArrays and CPointers that are used by FFI to be committed and faulted out, and lose C data. In this case, GsTsExternalSession >> send:to:withArguments: may pass NULL to GciTsPerform for the last argument; this results in a null pointer exception and a HostCallDebugger.

The null pointer exception and crash are fixed in versions 3.5.8 and 3.6.4 and later.  The issue causing loss of C data on fault is still present in these versions, and will error normally rather than crashing.

Workaround

Applications using GsTsExternalSession should install this patch to avoid the null pointer exception.

method: GsTsExternalSession
_signalError: aString
  | err |
  (err := GciError new) error: gciErr in: self details: nil .
  (err originalNumber between: 4000 and: 4999) ifTrue:[
    self _closeConnection . "ensure connection is closed after fatal error"
  ] ifFalse:[
    gciErr := GciErrSType new .
  ].
  err signal .
%

Last updated: 5/17/23