blob: 0fc865f599bfed82f14eb8d9a93f62252187a66e (
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
|
/* { dg-additional-options "-fanalyzer-show-duplicate-count" } */
#include <stdlib.h>
typedef struct _krb5_data {
char *data;
} krb5_data;
/* Ensure that we de-duplicate the various paths to reach here,
and only emit one diagnostic. */
void
recvauth_common(krb5_data inbuf)
{
free(inbuf.data);
free(inbuf.data); /* { dg-warning "double-'free'" "warning" } */
/* { dg-message "2 duplicates" "duplicates notification" { xfail *-*-* } .-1 } */
}
void krb5_recvauth(krb5_data inbuf)
{
recvauth_common(inbuf);
}
void krb5_recvauth_version(krb5_data inbuf)
{
recvauth_common(inbuf);
}
|