foot/user-notification.h
Daniel Eklöf c8e78674ed
slave: emit user-notifications before dup:ing stdin/stdout/stderr
Since we need to restore the status flags anyway, there's nothing to
gain from emitting the user notifications after dup:ing the pts file
descriptor.

On the other hand, emitting user notifications *before* dup:ing means
we can still print error messages for e.g. write(3) errors.
2020-08-01 09:00:18 +02:00

16 lines
308 B
C

#pragma once
#include <tllist.h>
enum user_notification_kind {
USER_NOTIFICATION_DEPRECATED,
USER_NOTIFICATION_WARNING,
USER_NOTIFICATION_ERROR,
};
struct user_notification {
enum user_notification_kind kind;
char *text;
};
typedef tll(struct user_notification) user_notifications_t;