jackxiao / jslibs

Automatically exported from code.google.com/p/jslibs
0 stars 0 forks source link

SharedMemory not closed properly #61

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
after 'jshost qa.js "shared memory"',
some files (like qa18jxmrz94u, qa18jxmrz94u_sem, ...) are not removed.
Check if finalize function if properly called.

Original issue reported on code.google.com by sou...@gmail.com on 18 Sep 2008 at 9:47

GoogleCodeExporter commented 9 years ago
with the following test:
  LoadModule('jsio');
  var fileName = 'qawww';
  var mem = new SharedMemory( fileName, 100 );
  mem.content = ' abcdef ';
  mem.Close();

CloseSharedMemory function is called but the 'if ( isLast ) ...' block is never
reached because in the test 'isLast = (mh->accessCount == 0)' accessCount is -1

Original comment by sou...@gmail.com on 18 Sep 2008 at 10:07

GoogleCodeExporter commented 9 years ago
The isLast condition was misplaced. 

Fixed At revision: 2012

Original comment by sou...@gmail.com on 18 Sep 2008 at 10:22