summaryrefslogtreecommitdiff
path: root/os/log.c
diff options
context:
space:
mode:
authorPaulo Cesar Pereira de Andrade <pcpa@mandriva.com.br>2008-12-03 05:43:34 -0200
committerPaulo Cesar Pereira de Andrade <pcpa@mandriva.com.br>2008-12-03 05:43:34 -0200
commit49f77fff1495c0a2050fb18f9b1fc627839bbfc2 (patch)
treeeebaec908150abfc0159d9ee941404918f553113 /os/log.c
parent0b8f8b24f718820a72ebdc52423c2e6a44e848c5 (diff)
Rework symbol visibility for easier maintenance
Save in a few special cases, _X_EXPORT should not be used in C source files. Instead, it should be used in headers, and the proper C source include that header. Some special cases are symbols that need to be shared between modules, but not expected to be used by external drivers, and symbols that are accessible via LoaderSymbol/dlopen. This patch also adds conditionally some new sdk header files, depending on extensions enabled. These files were added to match pattern for other extensions/modules, that is, have the headers "deciding" symbol visibility in the sdk. These headers are: o Xext/panoramiXsrv.h, Xext/panoramiX.h o fbpict.h (unconditionally) o vidmodeproc.h o mioverlay.h (unconditionally, used only by xaa) o xfixes.h (unconditionally, symbols required by dri2) LoaderSymbol and similar functions now don't have different prototypes, in loaderProcs.h and xf86Module.h, so that both headers can be included, without the need of defining IN_LOADER. xf86NewInputDevice() device prototype readded to xf86Xinput.h, but not exported (and with a comment about it).
Diffstat (limited to 'os/log.c')
-rw-r--r--os/log.c34
1 files changed, 17 insertions, 17 deletions
diff --git a/os/log.c b/os/log.c
index d65932449..351090cdc 100644
--- a/os/log.c
+++ b/os/log.c
@@ -100,7 +100,7 @@ OR PERFORMANCE OF THIS SOFTWARE.
#ifdef DDXOSVERRORF
-_X_EXPORT void (*OsVendorVErrorFProc)(const char *, va_list args) = NULL;
+void (*OsVendorVErrorFProc)(const char *, va_list args) = NULL;
#endif
static FILE *logFile = NULL;
@@ -155,7 +155,7 @@ static Bool needBuffer = TRUE;
* string.
*/
-_X_EXPORT const char *
+const char *
LogInit(const char *fname, const char *backup)
{
char *logFileName = NULL;
@@ -217,7 +217,7 @@ LogInit(const char *fname, const char *backup)
return logFileName;
}
-_X_EXPORT void
+void
LogClose(void)
{
if (logFile) {
@@ -226,7 +226,7 @@ LogClose(void)
}
}
-_X_EXPORT Bool
+Bool
LogSetParameter(LogParameter param, int value)
{
switch (param) {
@@ -249,7 +249,7 @@ LogSetParameter(LogParameter param, int value)
/* This function does the actual log message writes. */
-_X_EXPORT void
+void
LogVWrite(int verb, const char *f, va_list args)
{
static char tmpBuffer[1024];
@@ -298,7 +298,7 @@ LogVWrite(int verb, const char *f, va_list args)
}
}
-_X_EXPORT void
+void
LogWrite(int verb, const char *f, ...)
{
va_list args;
@@ -308,7 +308,7 @@ LogWrite(int verb, const char *f, ...)
va_end(args);
}
-_X_EXPORT void
+void
LogVMessageVerb(MessageType type, int verb, const char *format, va_list args)
{
const char *s = X_UNKNOWN_STRING;
@@ -373,7 +373,7 @@ LogVMessageVerb(MessageType type, int verb, const char *format, va_list args)
}
/* Log message with verbosity level specified. */
-_X_EXPORT void
+void
LogMessageVerb(MessageType type, int verb, const char *format, ...)
{
va_list ap;
@@ -384,7 +384,7 @@ LogMessageVerb(MessageType type, int verb, const char *format, ...)
}
/* Log a message with the standard verbosity level of 1. */
-_X_EXPORT void
+void
LogMessage(MessageType type, const char *format, ...)
{
va_list ap;
@@ -420,7 +420,7 @@ static int nrepeat = 0;
static int oldlen = -1;
static OsTimerPtr auditTimer = NULL;
-_X_EXPORT void
+void
FreeAuditTimer(void)
{
if (auditTimer != NULL) {
@@ -451,7 +451,7 @@ AuditPrefix(void)
return tmpBuf;
}
-_X_EXPORT void
+void
AuditF(const char * f, ...)
{
va_list args;
@@ -482,7 +482,7 @@ AuditFlush(OsTimerPtr timer, CARD32 now, pointer arg)
}
}
-_X_EXPORT void
+void
VAuditF(const char *f, va_list args)
{
char *prefix;
@@ -510,7 +510,7 @@ VAuditF(const char *f, va_list args)
free(prefix);
}
-_X_EXPORT void
+void
FatalError(const char *f, ...)
{
va_list args;
@@ -535,7 +535,7 @@ FatalError(const char *f, ...)
/*NOTREACHED*/
}
-_X_EXPORT void
+void
VErrorF(const char *f, va_list args)
{
#ifdef DDXOSVERRORF
@@ -548,7 +548,7 @@ VErrorF(const char *f, va_list args)
#endif
}
-_X_EXPORT void
+void
ErrorF(const char * f, ...)
{
va_list args;
@@ -560,7 +560,7 @@ ErrorF(const char * f, ...)
/* A perror() workalike. */
-_X_EXPORT void
+void
Error(char *str)
{
char *err = NULL;
@@ -577,7 +577,7 @@ Error(char *str)
LogWrite(-1, strerror(saveErrno));
}
-_X_EXPORT void
+void
LogPrintMarkers(void)
{
/* Show what the message marker symbols mean. */