* xmlEncConvertError: * @code: XML_ENC_ERR code * * Convert XML_ENC_ERR to libxml2 error codes. */
| 2141 | * Convert XML_ENC_ERR to libxml2 error codes. |
| 2142 | */ |
| 2143 | static int |
| 2144 | xmlEncConvertError(int code) { |
| 2145 | int ret; |
| 2146 | |
| 2147 | switch (code) { |
| 2148 | case XML_ENC_ERR_SUCCESS: |
| 2149 | ret = XML_ERR_OK; |
| 2150 | break; |
| 2151 | case XML_ENC_ERR_INPUT: |
| 2152 | ret = XML_ERR_INVALID_ENCODING; |
| 2153 | break; |
| 2154 | case XML_ENC_ERR_MEMORY: |
| 2155 | ret = XML_ERR_NO_MEMORY; |
| 2156 | break; |
| 2157 | default: |
| 2158 | ret = XML_ERR_INTERNAL_ERROR; |
| 2159 | break; |
| 2160 | } |
| 2161 | |
| 2162 | return(ret); |
| 2163 | } |
| 2164 | |
| 2165 | /** |
| 2166 | * xmlEncInputChunk: |
no outgoing calls
no test coverage detected