Added a -h option to sicslog querying
Fixed the mongodb path in sicslogmain to point to the production server
This commit is contained in:
@ -9,7 +9,7 @@
|
||||
#include <bson.h>
|
||||
#include <logv2.h>
|
||||
|
||||
static void formatSeverity(unsigned int severity, char *buffer, unsigned int bufferLength)
|
||||
void formatSeverity(unsigned int severity, char *buffer, unsigned int bufferLength)
|
||||
{
|
||||
static const char *severityText[] = {"FATAL",
|
||||
"ERROR",
|
||||
@ -25,6 +25,7 @@ static void formatSeverity(unsigned int severity, char *buffer, unsigned int buf
|
||||
}
|
||||
strncpy(buffer,severityText[severity-1],bufferLength);
|
||||
}
|
||||
|
||||
/*----------------------------------------------------------------------------------------*/
|
||||
static void ResultPrint(const bson_t *doc, void *userData)
|
||||
{
|
||||
@ -55,7 +56,7 @@ int main(int argc, char *argv[])
|
||||
int status;
|
||||
char *error;
|
||||
|
||||
sicslogSetup("mongodb://logwriter:sinqsics@localhost:27017/?authSource=admin",NULL);
|
||||
sicslogSetup("mongodb://logwriter:sinqsics@mpc1965:27017/?authSource=admin",NULL);
|
||||
status = sicslogQuery(argc,argv,ResultPrint,NULL);
|
||||
if(status != 0){
|
||||
error = sicslogGetError();
|
||||
|
Reference in New Issue
Block a user