File: globals.c

package info (click to toggle)
multipath-tools 0.14.3-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 4,088 kB
  • sloc: ansic: 64,885; perl: 1,622; makefile: 742; sh: 732; pascal: 155
file content (33 lines) | stat: -rw-r--r-- 588 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
#include <stdlib.h>
#include <string.h>

#include "defaults.h"
#include "structs.h"
#include "config.h"
#include "debug.h"

struct config conf;

struct config *get_multipath_config(void)
{
	return &conf;
}

void put_multipath_config(void *arg)
{}

static __attribute__((unused)) void init_test_verbosity(int test_verbosity)
{
	char *verb = getenv("MPATHTEST_VERBOSITY");

	libmp_verbosity = test_verbosity >= 0 ? test_verbosity :
		DEFAULT_VERBOSITY;
	if (verb && *verb) {
		char *c;
		int vb;

		vb = strtoul(verb, &c, 10);
		if (!*c && vb >= 0 && vb <= 5)
			libmp_verbosity = vb;
	}
}