* xmlParserInputBufferCreateFile: * @file: a FILE* * @enc: the charset encoding if known (deprecated) * * Create a buffered parser input for the progressive parsing of a FILE * * buffered C I/O * * The encoding argument is deprecated and should be set to * XML_CHAR_ENCODING_NONE. The encoding can be changed with * xmlSwitchEncoding or xmlSwitchEncodingName later on. * * Returns the ne
| 1792 | * Returns the new parser input or NULL |
| 1793 | */ |
| 1794 | xmlParserInputBufferPtr |
| 1795 | xmlParserInputBufferCreateFile(FILE *file, xmlCharEncoding enc) { |
| 1796 | xmlParserInputBufferPtr ret; |
| 1797 | |
| 1798 | if (file == NULL) return(NULL); |
| 1799 | |
| 1800 | ret = xmlAllocParserInputBuffer(enc); |
| 1801 | if (ret != NULL) { |
| 1802 | ret->context = file; |
| 1803 | ret->readcallback = xmlFileRead; |
| 1804 | ret->closecallback = NULL; |
| 1805 | } |
| 1806 | |
| 1807 | return(ret); |
| 1808 | } |
| 1809 | |
| 1810 | #ifdef LIBXML_OUTPUT_ENABLED |
| 1811 | /** |
nothing calls this directly
no test coverage detected