Fix C code compilation
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10100 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
39abd80eef
commit
6e88a9778f
1 changed files with 2 additions and 1 deletions
|
|
@ -273,13 +273,14 @@ SWIG_R_NewPointerObj(void *ptr, swig_type_info *type, int flags) {
|
|||
/* Convert a pointer value */
|
||||
SWIGRUNTIMEINLINE int
|
||||
SWIG_R_ConvertPtr(SEXP obj, void **ptr, swig_type_info *ty, int flags) {
|
||||
void *vptr;
|
||||
if (!obj) return SWIG_ERROR;
|
||||
if (obj == R_NilValue) {
|
||||
if (ptr) *ptr = NULL;
|
||||
return SWIG_OK;
|
||||
}
|
||||
|
||||
void *vptr = R_ExternalPtrAddr(obj);
|
||||
vptr = R_ExternalPtrAddr(obj);
|
||||
if (ty) {
|
||||
swig_type_info *to = (swig_type_info*)
|
||||
R_ExternalPtrAddr(R_ExternalPtrTag(obj));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue