c based logging api