This should usually never happen.
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
#include <pakfire/buffer.h>
#include <pakfire/ctx.h>
#include <pakfire/log_stream.h>
+#include <pakfire/util.h>
#define MAX_LINE_LENGTH 16384
int r;
// Log a message if we don't have a callback
- if (!stream->callback) {
- ERROR(stream->ctx, "Log stream has no callback set\n");
- return -EINVAL;
+ if (unlikely(!stream->callback)) {
+ DEBUG(stream->ctx, "Log stream has no callback set\n");
+ return 0;
}
for (;;) {