Coranac

grit mini-fix

2007-06-29 – 0:00 | .

Small fix for grit. The function that handles the extensions didn't add the extension-period as it should if no extension was given in the -o option. ‘-ofoo’ would result in things like foos and foosh.

This is a one-line fix, by the way. In /libgrit/pathfun.cpp, function path_repl_ext(), replace this:

    if(pext)
        strcpy(pext, ext);			
    else
        strcat(str, ext);
by this
    if(pext)
        strcpy(pext, ext);			
    else
    {
        strcat(str, ".");
        strcat(str, ext);
    }

This is not really a critical update. As long as there's an extension-period inside the -o option, or if there was no -o to start with, it should work fine as is.


No Comments »

No comments yet.

RSS feed for comments on this post. TrackBack URL

Leave a comment




XHTML: You can use these tags:<a href=""> <b> <blockquote cite=""> <br> <cite> <code> <div align="" class=""> <em> <i> <li> <ol> <p> <q cite=""> <sub> <sup> <u> <ul>
Others: [br], [code lang='*'], [color], [url], [wiki]




Powered by WordPress