Open Bug 1523622 Opened 4 years ago Updated 3 years ago

Mac OS X leak in updaterfileutils_osx.mm IsRecursivelyWritable

Categories

(Toolkit :: Application Update, defect, P3)

59 Branch
Unspecified
macOS
defect

Tracking

()

People

(Reporter: robert.strong.bugs, Unassigned)

References

(Blocks 1 open bug)

Details

Direct leak of 44 byte(s) in 1 object(s) allocated from:
#0 0x10f49c233 in wrap_malloc (/usr/local/opt/llvm/lib/clang/7.0.1/lib/darwin/libclang_rt.asan_osx_dynamic.dylib:x86_64+0x59233)
#1 0x7fff6cefe8b2 in _Block_copy (/usr/lib/system/libsystem_blocks.dylib:x86_64+0x8b2)
#2 0x7fff6ce7703b in _dispatch_Block_copy (/usr/lib/system/libdispatch.dylib:x86_64+0x203b)
#3 0x7fff6ce780d8 in dispatch_source_set_event_handler (/usr/lib/system/libdispatch.dylib:x86_64+0x30d8)
#4 0x10f49b779 in wrap_dispatch_source_set_event_handler (/usr/local/opt/llvm/lib/clang/7.0.1/lib/darwin/libclang_rt.asan_osx_dynamic.dylib:x86_64+0x58779)
#5 0x7fff44ec7c42 in __CFRunLoopFindMode (/System/Library/Frameworks/CoreFoundation.framework/Versions/A/CoreFoundation:x86_64+0x50c42)
#6 0x7fff44ec787f in __CFRunLoopCreate (/System/Library/Frameworks/CoreFoundation.framework/Versions/A/CoreFoundation:x86_64+0x5087f)
#7 0x7fff44ec7531 in _CFRunLoopGet0 (/System/Library/Frameworks/CoreFoundation.framework/Versions/A/CoreFoundation:x86_64+0x50531)
#8 0x7fff589a982d in _FSURLEndResourcePropertyCacheAccess (/System/Library/PrivateFrameworks/CoreServicesInternal.framework/Versions/A/CoreServicesInternal:x86_64+0xa82d)
#9 0x7fff44f0aa5d in -[NSURL resourceValuesForKeys:error:] (/System/Library/Frameworks/CoreFoundation.framework/Versions/A/CoreFoundation:x86_64+0x93a5d)
#10 0x7fff47032415 in +[NSFileAttributes _populateCatInfo:forURL:statInfo:error:] (/System/Library/Frameworks/Foundation.framework/Versions/C/Foundation:x86_64+0x42415)
#11 0x7fff470322e5 in +[NSFileAttributes _attributesAtPath:partialReturn:filterResourceFork:error:] (/System/Library/Frameworks/Foundation.framework/Versions/C/Foundation:x86_64+0x422e5)
#12 0x10f413094 in IsRecursivelyWritable (<objdir>/dist/Nightly/updates/0/updater.app/Contents/MacOS/org.mozilla.updater:x86_64+0x100015094)
#13 0x10f407446 in main (<objdir>/dist/Nightly/updates/0/updater.app/Contents/MacOS/org.mozilla.updater:x86_64+0x100009446)
#14 0x7fff6ceb0014 in start (/usr/lib/system/libdyld.dylib:x86_64+0x1014)

Stephen, no rush on this either but if you could fix this as time permits I'd appreciate it.

This callstack seems to indicate that it is actually the OS that's leaking this object... I'm not sure if we're going to be able to fix this, unless we rewrite IsRecursivelyWritable somehow to no longer use NSFileManager's attributesOfItemAtPath:error:...

Priority: -- → P3
OS: Unspecified → macOS
You need to log in before you can comment on or make changes to this bug.