davidxu     2005-12-16 02:50:53 UTC

  FreeBSD src repository

  Modified files:
    lib/libc/stdio       fread.c local.h vfscanf.c 
  Log:
  With current pthread implementations, a mutex initialization will
  allocate a memory block. sscanf calls __svfscanf which in turn calls
  fread, fread triggers mutex initialization but the mutex is not
  destroyed in sscanf, this leads to memory leak. To avoid the memory
  leak and performance issue, we create a none MT-safe version of fread:
  __fread, and instead let __svfscanf call __fread.
  
  PR: threads/90392
  Patch submitted by: dhartmei
  MFC after: 7 days
  
  Revision  Changes    Path
  1.13      +16 -7     src/lib/libc/stdio/fread.c
  1.28      +2 -1      src/lib/libc/stdio/local.h
  1.39      +1 -1      src/lib/libc/stdio/vfscanf.c
_______________________________________________
[email protected] mailing list
http://lists.freebsd.org/mailman/listinfo/cvs-all
To unsubscribe, send any mail to "[EMAIL PROTECTED]"

Reply via email to