toolbox

Check-in [cf9ec4c414]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:http-code: fix mixed indentation typo
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256:cf9ec4c4146ee4b8b52c112afa4e19af9336e67af5e0fa658d1a7f21128f4d16
User & Date: jef 2019-05-02 21:38:21
Context
2019-05-03
07:42
http-code: add flag to enable redirects check-in: 564880f6c2 user: jef tags: trunk
2019-05-02
21:38
http-code: fix mixed indentation typo check-in: cf9ec4c414 user: jef tags: trunk
21:32
http-code: add timeout flag check-in: f1da0d93bc user: jef tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to src/http-code/http-code.c.

26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
long
parse_timeout(char *str)
{
	long value;
	int nparsed;

	if (sscanf(str, "%ld%n", &value, &nparsed) == 1
                        && strlen(str) == (size_t) nparsed
			&& value >= 0)
		return value;

	die("invalid timeout argument '%s'", str);
	return 0;
}








|







26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
long
parse_timeout(char *str)
{
	long value;
	int nparsed;

	if (sscanf(str, "%ld%n", &value, &nparsed) == 1
			&& strlen(str) == (size_t) nparsed
			&& value >= 0)
		return value;

	die("invalid timeout argument '%s'", str);
	return 0;
}