• Show log

    Commit

  • Hash : 14109620
    Author : Patrick Steinhardt
    Date : 2017-04-28T14:03:54

    odb: improve error handling in read_prefix_1
    
    The read_prefix_1 function has several return statements springled
    throughout the code. As we have to free memory upon getting an error,
    the free code has to be repeated at every single retrun -- which it is
    not, so we have a memory leak here.
    
    Refactor the code to use the typical `goto out` pattern, which will free
    data when an error has occurred. While we're at it, we can also improve
    the error message thrown when multiple ambiguous prefixes are found. It
    will now include the colliding prefixes.