Fix error in generated code for Python in MSVC 2019.
Visual Studio 2019 release builds: error C4703: potentially uninitialized local pointer variable 'p' used
This commit is contained in:
parent
c48d11ac17
commit
9fc57f47bd
5 changed files with 6 additions and 6 deletions
|
|
@ -101,7 +101,7 @@
|
|||
%#endif
|
||||
res = traits_asptr_stdseq<map_type, std::pair<K, T> >::asptr(items, val);
|
||||
} else {
|
||||
map_type *p;
|
||||
map_type *p = 0;
|
||||
swig_type_info *descriptor = swig::type_info<map_type>();
|
||||
res = descriptor ? SWIG_ConvertPtr(obj, (void **)&p, descriptor, 0) : SWIG_ERROR;
|
||||
if (SWIG_IsOK(res) && val) *val = p;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue