log lib for c