mirror of
https://github.com/kovidgoyal/kitty
synced 2026-06-08 22:28:24 +02:00
Add a printf annotation of the log_error function
This commit is contained in:
@@ -27,7 +27,7 @@
|
||||
#define xstr(s) str(s)
|
||||
#define str(s) #s
|
||||
#define arraysz(x) (sizeof(x)/sizeof(x[0]))
|
||||
void log_error(const char *fmt, ...);
|
||||
void log_error(const char *fmt, ...) __attribute__ ((format (printf, 1, 2)));
|
||||
#define fatal(...) { log_error(__VA_ARGS__); exit(EXIT_FAILURE); }
|
||||
|
||||
typedef unsigned long long id_type;
|
||||
|
||||
@@ -1105,7 +1105,7 @@ initialize_font(FontGroup *fg, unsigned int desc_idx, const char *ftype) {
|
||||
Py_CLEAR(face);
|
||||
if (!ok) {
|
||||
if (PyErr_Occurred()) { PyErr_Print(); }
|
||||
fatal("Failed to initialize %s font: %d", ftype, idx);
|
||||
fatal("Failed to initialize %s font: %zu", ftype, idx);
|
||||
}
|
||||
return idx;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user