| 2124 | } |
| 2125 | |
| 2126 | static FILE* callfopen( const char* filepath, const char* mode ) |
| 2127 | { |
| 2128 | TIXMLASSERT( filepath ); |
| 2129 | TIXMLASSERT( mode ); |
| 2130 | #if defined(_MSC_VER) && (_MSC_VER >= 1400 ) && (!defined WINCE) |
| 2131 | FILE* fp = 0; |
| 2132 | errno_t err = fopen_s( &fp, filepath, mode ); |
| 2133 | if ( err ) { |
| 2134 | return 0; |
| 2135 | } |
| 2136 | #else |
| 2137 | FILE* fp = fopen( filepath, mode ); |
| 2138 | #endif |
| 2139 | return fp; |
| 2140 | } |
| 2141 | |
| 2142 | void XMLDocument::DeleteNode( XMLNode* node ) { |
| 2143 | TIXMLASSERT( node ); |