Skip to content

Conversation

@paulb777
Copy link
Member

@paulb777 paulb777 commented Nov 28, 2025

Log error to help debug firebase/firebase-ios-sdk#15414

@google-oss-bot
Copy link

google-oss-bot commented Nov 28, 2025

Coverage Report 1

Affected Products

  • GoogleDataTransport-ios-GoogleDataTransport.framework

    Overall coverage changed from 50.40% (17eb3cb) to 63.10% (a2631f8) by +12.70%.

    28 individual files with coverage change

    FilenameBase (17eb3cb)Merge (a2631f8)Diff
    GDTCCTCompressionHelper.m81.63%0.00%-81.63%
    GDTCCTNanopbHelpers.m56.30%0.00%-56.30%
    GDTCCTUploader.m91.33%54.00%-37.33%
    GDTCCTUploadOperation.m90.77%28.41%-62.36%
    GDTCCTURLSessionDataResponse.m100.00%0.00%-100.00%
    GDTCORAssert.m0.00%88.89%+88.89%
    GDTCORClock.m70.24%85.71%+15.48%
    GDTCORConsoleLogger.m20.00%76.00%+56.00%
    GDTCORDirectorySizeTracker.m67.27%93.44%+26.17%
    GDTCOREvent+GDTCCTSupport.m35.05%0.00%-35.05%
    GDTCOREvent+GDTMetricsSupport.m75.00%0.00%-75.00%
    GDTCOREvent.m60.92%97.70%+36.78%
    GDTCORFlatFileStorage+Promises.m18.97%46.55%+27.59%
    GDTCORFlatFileStorage.m21.38%91.04%+69.65%
    GDTCORLifecycle.m39.24%54.43%+15.19%
    GDTCORLogSourceMetrics.m52.63%93.86%+41.23%
    GDTCORMetrics+GDTCCTSupport.m93.75%0.00%-93.75%
    GDTCORMetrics.m47.27%40.00%-7.27%
    GDTCORMetricsController.m15.88%94.71%+78.82%
    GDTCORMetricsMetadata.m0.00%100.00%+100.00%
    GDTCORPlatform.m59.35%72.26%+12.90%
    GDTCORProductData.m40.54%83.78%+43.24%
    GDTCORRegistrar.m76.88%79.57%+2.69%
    GDTCORStorageMetadata.m0.00%100.00%+100.00%
    GDTCORTransformer.m0.00%91.09%+91.09%
    GDTCORTransport.m0.00%84.09%+84.09%
    GDTCORUploadBatch.m100.00%0.00%-100.00%
    GDTCORUploadCoordinator.m62.00%80.00%+18.00%

Test Logs

  1. https://storage.googleapis.com/firebase-sdk-metric-reports/UjlzJJfGLY.html

@paulb777 paulb777 requested a review from ncooke3 December 1, 2025 14:10
Copy link
Member

@ncooke3 ncooke3 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Based on the trace firebase/firebase-ios-sdk#15414 (comment), we crash on enumeration due to a non-recoverable error in malloc, so we won't get to the error handler.

So I don't think we should change the error handler's return value because it could affect behavior in other cases and result in inaccurate sizing.

This won't fix the crash but we could log the error in the handler. It's possibly it could help further debugging.

If memory is corrupted from somewhere else, looping over the file system may be what is increasing the odds of trying to allocate this corrupted memory.

I audited how we use nanopb (C) and didn't find any memory vulnerabilites.

paulb777 and others added 5 commits December 8, 2025 16:00
Co-authored-by: Nick Cooke <36927374+ncooke3@users.noreply.github.com>
…rTests.m

Co-authored-by: Nick Cooke <36927374+ncooke3@users.noreply.github.com>
@ncooke3 ncooke3 merged commit 559c9c6 into main Dec 9, 2025
8 checks passed
@ncooke3 ncooke3 deleted the pb-fix-crash2 branch December 9, 2025 14:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants