blob: 1fcf6263f7e0a6c9df355d44220c791d9058974c (
plain)
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
|
/* Template: generic */
/*
* No error
*/
{
guint64 size = g_ascii_strtoull ("some-constant-string", NULL, 10);
}
/*
* No error
*/
{
const gchar *some_str = "foo";
guint64 size = g_ascii_strtoull (some_str, NULL, 10);
}
/*
* No error
*/
{
const gchar *endptr = NULL;
guint64 size = g_ascii_strtoull ("some-constant-string", (gchar **) &endptr, 10);
}
/*
* null passed to a callee which requires a non-null argument
* guint64 size = g_ascii_strtoull (NULL, NULL, 10);
* ~~~~ ^
*/
{
guint64 size = g_ascii_strtoull (NULL, NULL, 10);
}
|