Closed ChunMinChang closed 4 years ago
This causes different behavior of what we do in C backends.
To make the log consistent, we could probably do the following in cubeb_log.h.
#define __FILENAME__ (__builtin_strrchr(__FILE__, '/') ? __builtin_strrchr(__FILE__, '/') + 1 : __FILE__)
g_cubeb_log_callback("%s:%d: " fmt "\n", __FILENAME__, __LINE__, ##__VA_ARGS__);
Thanks, LGTM.
This causes different behavior of what we do in C backends.
Your suggestions for addressing this seems good.
Instead of printing the full path to the file that is currently running, we should print the filename only. As long as we have the filename and the line, we know where the log comes from.
This is a fix for BMO 1628132. r? @kinetiknz
This change is