megvii: Return a char pointer for some stubs instead
`mg_facepp[3]` and `mg_facepp[4]` seem to return version strings, which occasionally get logged if the return value is non-zero. Return a dummy string for those functions to avoid crashing in strlen. Change-Id: Icc5d2ab2f72c480f03e652e3849aceaf4cfb498b
This commit is contained in:
parent
ec5d5b0a98
commit
5f0d7bbbe8
@ -8,12 +8,16 @@ static int stub_fail() {
|
|||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static char *stub_fail_str() {
|
||||||
|
return "stub";
|
||||||
|
}
|
||||||
|
|
||||||
void *mg_facepp[] = {
|
void *mg_facepp[] = {
|
||||||
&stub_fail,
|
&stub_fail,
|
||||||
&stub_fail,
|
&stub_fail,
|
||||||
&stub_fail,
|
&stub_fail,
|
||||||
&stub_fail,
|
&stub_fail_str,
|
||||||
&stub_fail,
|
&stub_fail_str,
|
||||||
&stub_fail,
|
&stub_fail,
|
||||||
&stub_fail,
|
&stub_fail,
|
||||||
&stub_fail,
|
&stub_fail,
|
||||||
|
Loading…
Reference in New Issue
Block a user