From 9dd2447d42fd6c822139f3cd1fd2cd284346e5e8 Mon Sep 17 00:00:00 2001 From: Robin Haberkorn Date: Fri, 1 Feb 2013 19:34:23 +0100 Subject: fixed buffer Ring initialization * there was a dependency on interface initialization. it did not cause issues because destruction order was by chance. * introduced INIT_PRIO and PRIO_* macros to easy initialization order declaration (using a PRIO_* formula makes code self-documenting) * also used this to clean up QRegisterTable initialization (we do not need the explicit initialize() method) * also used to clean up symbols initialization --- src/sciteco.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/sciteco.h') diff --git a/src/sciteco.h b/src/sciteco.h index 441b262..e129a4c 100644 --- a/src/sciteco.h +++ b/src/sciteco.h @@ -34,6 +34,10 @@ namespace Flags { extern sig_atomic_t sigint_occurred; +#define INIT_PRIO(X) __attribute__((init_priority(X))) +#define PRIO_INTERFACE 1000 +#define PRIO_SYMBOLS 1000 + #define IS_CTL(C) ((C) < ' ') #define CTL_ECHO(C) ((C) | 0x40) #define CTL_KEY(C) ((C) & ~0x40) -- cgit v1.2.3