X-Git-Url: https://code.citadel.org/?a=blobdiff_plain;ds=sidebyside;f=citadel%2Fmodules%2Fextnotify%2Ffunambol65.c;fp=citadel%2Fmodules%2Fextnotify%2Ffunambol65.c;h=5cd7c4d9eda718e990749ee7fc05bce28d89451f;hb=f1ee61891901850ebbdee1e9440b363dc6df540a;hp=f81b41dbfadcdc5adba62d58ab25f4437b464c39;hpb=2d03b6864a657a706b8d2917d912e579b2298025;p=citadel.git diff --git a/citadel/modules/extnotify/funambol65.c b/citadel/modules/extnotify/funambol65.c index f81b41dbf..5cd7c4d9e 100644 --- a/citadel/modules/extnotify/funambol65.c +++ b/citadel/modules/extnotify/funambol65.c @@ -90,7 +90,7 @@ int notify_http_server(char *remoteurl, snprintf(buf, SIZ, "Cannot load template file %s [%s]won't send notification\r\n", file_funambol_msg, strerror(errno)); - CtdlLogPrintf(CTDL_ERR, buf); + syslog(LOG_ERR, buf); CtdlAideMessage(buf, "External notifier unable to find message template!"); goto abort; @@ -113,7 +113,7 @@ int notify_http_server(char *remoteurl, snprintf(buf, SIZ, "Cannot load template file %s; won't send notification\r\n", file_funambol_msg); - CtdlLogPrintf(CTDL_ERR, buf); + syslog(LOG_ERR, buf); CtdlAideMessage(buf, "External notifier unable to load message template!"); goto abort; @@ -158,7 +158,7 @@ int notify_http_server(char *remoteurl, EvaluateResult, ExtNotifyTerminate)) { - CtdlLogPrintf(CTDL_ALERT, "Unable to initialize libcurl.\n"); + syslog(LOG_ALERT, "Unable to initialize libcurl.\n"); goto abort; } chnd = IO->HttpReq.chnd; @@ -198,9 +198,10 @@ eNextState EvaluateResult(AsyncIO *IO) if (IO->HttpReq.httpcode != 200) { StrBuf *ErrMsg; - CtdlLogPrintf(CTDL_ALERT, "libcurl error %ld: %s\n", + syslog(LOG_ALERT, "libcurl error %ld: %s\n", IO->HttpReq.httpcode, IO->HttpReq.errdesc); + ErrMsg = NewStrBufPlain(HKEY("Error sending your Notification\n")); StrBufAppendPrintf(ErrMsg, "\nlibcurl error %ld: \n\t\t%s\n", IO->HttpReq.httpcode, @@ -224,7 +225,7 @@ eNextState EvaluateResult(AsyncIO *IO) CtdlAideMessage(ChrPtr(ErrMsg), "External notifier unable to load message template!"); } - CtdlLogPrintf(CTDL_DEBUG, "Funambol notified\n"); + syslog(LOG_DEBUG, "Funambol notified\n"); /* while ((Ctx.NotifyHostList != NULL) && (Ctx.NotifyHostList[i] != NULL)) FreeStrBuf(&Ctx.NotifyHostList[i]);