~ubuntu-branches/ubuntu/dapper/monit/dapper

« back to all changes in this revision

Viewing changes to status.c

  • Committer: Bazaar Package Importer
  • Author(s): Stefan Alfredsson
  • Date: 2005-11-11 21:04:32 UTC
  • mfrom: (1.1.2 upstream)
  • Revision ID: james.westby@ubuntu.com-20051111210432-uqstfeqxun0vvn1j
Tags: 1:4.6-1
New upstream release (Closes: #306259, #308369, #315638)

Show diffs side-by-side

added added

removed removed

Lines of Context:
60
60
 *  @author Jan-Henrik Haukeland, <hauk@tildeslash.com>
61
61
 *  @author Christian Hopp, <chopp@iei.tu-clausthal.de>
62
62
 *
63
 
 *  @version \$Id: status.c,v 1.56 2005/01/06 20:51:49 martinp Exp $
 
63
 *  @version \$Id: status.c,v 1.57 2005/04/05 19:52:57 martinp Exp $
64
64
 *
65
65
 *  @file
66
66
 */
72
72
/**
73
73
 * Show all services in the service list
74
74
 */
75
 
void status() {
 
75
void status(char *level) {
76
76
 
77
77
#define LINE 1024
78
78
 
89
89
      char *auth= Util_getBasicAuthHeader();
90
90
      
91
91
      socket_print(sock, 
92
 
                   "GET /_status?format=text HTTP/1.0\r\n%s\r\n",
93
 
                   auth?auth:"");
 
92
                   "GET /_status?format=text&level=%s HTTP/1.0\r\n%s\r\n",
 
93
                   level, auth?auth:"");
94
94
      FREE(auth);
95
95
      /* Read past HTTP headers and check status */
96
96
      while(socket_readln(sock, buf, LINE)) {