Gitiles
Code Review
Sign In
gerrit-public.fairphone.software
/
fp2-dev
/
platform
/
external
/
clang
/
ee0feec7362053f22b6c01d12e1bfa06fb3ac93f
/
.
/
test
/
Analysis
/
div-zero.cpp
blob: d1261dc57335ed5784d625032538973c10a2fa53 [
file
] [
log
] [
blame
]
// RUN: %clang_cc1 -analyze -analyzer-checker=core.DivideZero -verify %s
int
fooPR10616
(
int
qX
)
{
int
a
,
c
,
d
;
d
=
(
qX
-
1
);
while
(
d
!=
0
)
{
d
=
c
-
(
c
/
d
)
*
d
;
}
return
(
a
%
(
qX
-
1
));
// expected-warning {{Division by zero}}
}