"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "src/http/client.c" between
monit-5.27.2.tar.gz and monit-5.28.0.tar.gz

About: Monit is a utility for managing and monitoring processes, files, directories and filesystems (with automatic error recovery).

client.c  (monit-5.27.2):client.c  (monit-5.28.0)
skipping to change at line 58 skipping to change at line 58
#include <strings.h> #include <strings.h>
#endif #endif
#ifdef HAVE_UNISTD_H #ifdef HAVE_UNISTD_H
#include <unistd.h> #include <unistd.h>
#endif #endif
#include "monit.h" #include "monit.h"
#include "ProcessTree.h" #include "ProcessTree.h"
#include "device.h" #include "device.h"
#include "Color.h" #include "TextColor.h"
#include "Box.h" #include "TextBox.h"
#include "client.h" #include "client.h"
// libmonit // libmonit
#include "exceptions/AssertException.h" #include "exceptions/AssertException.h"
#include "exceptions/IOException.h" #include "exceptions/IOException.h"
/** /**
* The monit HTTP GUI client * The monit HTTP GUI client
* *
* @file * @file
skipping to change at line 160 skipping to change at line 160
_auth ? _auth : "", _auth ? _auth : "",
StringBuffer_toString(data)); StringBuffer_toString(data));
FREE(_auth); FREE(_auth);
if (rv < 0) if (rv < 0)
THROW(IOException, "Monit: cannot send command to the monit daem on -- %s", STRERROR); THROW(IOException, "Monit: cannot send command to the monit daem on -- %s", STRERROR);
} }
static void _receive(Socket_T S) { static void _receive(Socket_T S) {
char buf[1024]; char buf[1024];
_parseHttpResponse(S); _parseHttpResponse(S);
bool strip = (Run.flags & Run_Batch || ! Color_support()) ? true : false ; bool strip = (Run.flags & Run_Batch || ! TextColor_support()) ? true : f alse;
while (Socket_readLine(S, buf, sizeof(buf))) { while (Socket_readLine(S, buf, sizeof(buf))) {
if (strip) if (strip)
Color_strip(Box_strip(buf)); TextColor_strip(TextBox_strip(buf));
printf("%s", buf); printf("%s", buf);
} }
} }
static bool _client(const char *request, StringBuffer_T data) { static bool _client(const char *request, StringBuffer_T data) {
volatile bool status = false; volatile bool status = false;
if (! exist_daemon()) { if (! exist_daemon()) {
Log_error("Monit: the monit daemon is not running\n"); Log_error("Monit: the monit daemon is not running\n");
return status; return status;
} }
 End of changes. 3 change blocks. 
4 lines changed or deleted 4 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)