XMLWordPrintableJSON

Details

    • Sub-task
    • Status: Open
    • Minor
    • Resolution: Unresolved
    • None
    • None
    • hdfs-client
    • None

    Description

      There's a few places we use C's assert, in a lot of applications it would be better to switch to something that doesn't necessarily call abort() right away.

      Example would be a large program that uses temp files or is responsible for freeing shared memory used for IPC. Aborting the process will clean up resources private to the process but leave other sorts of resources hanging around. If assert is replaced by a different macro it could throw or signal to indicate that it's no longer safe to use the library but give the rest of the application a chance to clean up unrelated resources.

      I'd also be nice to have a variant that wasn't compiled out on release builds for inexpensive checks. There have been issues in the past where even -O2 optimized release builds were able to collapse templates/inline/devirtualize things such that code that looked like it had been working started acting weird (was relying on UB) and catching that with existing checks would be valuable.

      Attachments

        Activity

          People

            Unassigned Unassigned
            James C James Clampffer
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: