亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲蟲下載站

?? debugxml.c

?? xml開源解析代碼.版本為libxml2-2.6.29,可支持GB3212.網(wǎng)絡(luò)消息發(fā)送XML時很有用.
?? C
?? 第 1 頁 / 共 5 頁
字號:
/* * debugXML.c : This is a set of routines used for debugging the tree *              produced by the XML parser. * * See Copyright for the status of this software. * * Daniel Veillard <daniel@veillard.com> */#define IN_LIBXML#include "libxml.h"#ifdef LIBXML_DEBUG_ENABLED#include <string.h>#ifdef HAVE_STDLIB_H#include <stdlib.h>#endif#ifdef HAVE_STRING_H#include <string.h>#endif#include <libxml/xmlmemory.h>#include <libxml/tree.h>#include <libxml/parser.h>#include <libxml/parserInternals.h>#include <libxml/valid.h>#include <libxml/debugXML.h>#include <libxml/HTMLtree.h>#include <libxml/HTMLparser.h>#include <libxml/xmlerror.h>#include <libxml/globals.h>#include <libxml/xpathInternals.h>#include <libxml/uri.h>#ifdef LIBXML_SCHEMAS_ENABLED#include <libxml/relaxng.h>#endif#define DUMP_TEXT_TYPE 1typedef struct _xmlDebugCtxt xmlDebugCtxt;typedef xmlDebugCtxt *xmlDebugCtxtPtr;struct _xmlDebugCtxt {    FILE *output;               /* the output file */    char shift[101];            /* used for indenting */    int depth;                  /* current depth */    xmlDocPtr doc;              /* current document */    xmlNodePtr node;		/* current node */    xmlDictPtr dict;		/* the doc dictionnary */    int check;                  /* do just checkings */    int errors;                 /* number of errors found */    int nodict;			/* if the document has no dictionnary */    int options;		/* options */};static void xmlCtxtDumpNodeList(xmlDebugCtxtPtr ctxt, xmlNodePtr node);static voidxmlCtxtDumpInitCtxt(xmlDebugCtxtPtr ctxt){    int i;    ctxt->depth = 0;    ctxt->check = 0;    ctxt->errors = 0;    ctxt->output = stdout;    ctxt->doc = NULL;    ctxt->node = NULL;    ctxt->dict = NULL;    ctxt->nodict = 0;    ctxt->options = 0;    for (i = 0; i < 100; i++)        ctxt->shift[i] = ' ';    ctxt->shift[100] = 0;}static voidxmlCtxtDumpCleanCtxt(xmlDebugCtxtPtr ctxt ATTRIBUTE_UNUSED){ /* remove the ATTRIBUTE_UNUSED when this is added */}/** * xmlNsCheckScope: * @node: the node * @ns: the namespace node * * Check that a given namespace is in scope on a node. * * Returns 1 if in scope, -1 in case of argument error,  *         -2 if the namespace is not in scope, and -3 if not on *         an ancestor node. */static intxmlNsCheckScope(xmlNodePtr node, xmlNsPtr ns){    xmlNsPtr cur;    if ((node == NULL) || (ns == NULL))        return(-1);    if ((node->type != XML_ELEMENT_NODE) &&	(node->type != XML_ATTRIBUTE_NODE) &&	(node->type != XML_DOCUMENT_NODE) &&	(node->type != XML_TEXT_NODE) &&	(node->type != XML_HTML_DOCUMENT_NODE) &&	(node->type != XML_XINCLUDE_START))	return(-2);    while ((node != NULL) &&           ((node->type == XML_ELEMENT_NODE) ||            (node->type == XML_ATTRIBUTE_NODE) ||            (node->type == XML_TEXT_NODE) ||	    (node->type == XML_XINCLUDE_START))) {	if ((node->type == XML_ELEMENT_NODE) ||	    (node->type == XML_XINCLUDE_START)) {	    cur = node->nsDef;	    while (cur != NULL) {	        if (cur == ns)		    return(1);		if (xmlStrEqual(cur->prefix, ns->prefix))		    return(-2);		cur = cur->next;	    }	}	node = node->parent;    }    /* the xml namespace may be declared on the document node */    if ((node != NULL) &&        ((node->type == XML_DOCUMENT_NODE) ||	 (node->type == XML_HTML_DOCUMENT_NODE))) {	 xmlNsPtr oldNs = ((xmlDocPtr) node)->oldNs;	 if (oldNs == ns)	     return(1);    }    return(-3);}static voidxmlCtxtDumpSpaces(xmlDebugCtxtPtr ctxt){    if (ctxt->check)        return;    if ((ctxt->output != NULL) && (ctxt->depth > 0)) {        if (ctxt->depth < 50)            fprintf(ctxt->output, &ctxt->shift[100 - 2 * ctxt->depth]);        else            fprintf(ctxt->output, ctxt->shift);    }}/** * xmlDebugErr: * @ctxt:  a debug context * @error:  the error code * * Handle a debug error. */static voidxmlDebugErr(xmlDebugCtxtPtr ctxt, int error, const char *msg){    ctxt->errors++;    __xmlRaiseError(NULL, NULL, NULL,		    NULL, ctxt->node, XML_FROM_CHECK,		    error, XML_ERR_ERROR, NULL, 0,		    NULL, NULL, NULL, 0, 0,		    msg);}static voidxmlDebugErr2(xmlDebugCtxtPtr ctxt, int error, const char *msg, int extra){    ctxt->errors++;    __xmlRaiseError(NULL, NULL, NULL,		    NULL, ctxt->node, XML_FROM_CHECK,		    error, XML_ERR_ERROR, NULL, 0,		    NULL, NULL, NULL, 0, 0,		    msg, extra);}static voidxmlDebugErr3(xmlDebugCtxtPtr ctxt, int error, const char *msg, const char *extra){    ctxt->errors++;    __xmlRaiseError(NULL, NULL, NULL,		    NULL, ctxt->node, XML_FROM_CHECK,		    error, XML_ERR_ERROR, NULL, 0,		    NULL, NULL, NULL, 0, 0,		    msg, extra);}/** * xmlCtxtNsCheckScope: * @ctxt: the debugging context * @node: the node * @ns: the namespace node * * Report if a given namespace is is not in scope. */static voidxmlCtxtNsCheckScope(xmlDebugCtxtPtr ctxt, xmlNodePtr node, xmlNsPtr ns){    int ret;    ret = xmlNsCheckScope(node, ns);    if (ret == -2) {        if (ns->prefix == NULL)	    xmlDebugErr(ctxt, XML_CHECK_NS_SCOPE,			"Reference to default namespace not in scope\n");	else	    xmlDebugErr3(ctxt, XML_CHECK_NS_SCOPE,			 "Reference to namespace '%s' not in scope\n",			 (char *) ns->prefix);    }    if (ret == -3) {        if (ns->prefix == NULL)	    xmlDebugErr(ctxt, XML_CHECK_NS_ANCESTOR,			"Reference to default namespace not on ancestor\n");	else	    xmlDebugErr3(ctxt, XML_CHECK_NS_ANCESTOR,			 "Reference to namespace '%s' not on ancestor\n",			 (char *) ns->prefix);    }}/** * xmlCtxtCheckString: * @ctxt: the debug context * @str: the string * * Do debugging on the string, currently it just checks the UTF-8 content */static voidxmlCtxtCheckString(xmlDebugCtxtPtr ctxt, const xmlChar * str){    if (str == NULL) return;    if (ctxt->check) {        if (!xmlCheckUTF8(str)) {	    xmlDebugErr3(ctxt, XML_CHECK_NOT_UTF8,			 "String is not UTF-8 %s", (const char *) str);	}    }}/** * xmlCtxtCheckName: * @ctxt: the debug context * @name: the name * * Do debugging on the name, for example the dictionnary status and * conformance to the Name production. */static voidxmlCtxtCheckName(xmlDebugCtxtPtr ctxt, const xmlChar * name){    if (ctxt->check) {	if (name == NULL) {	    xmlDebugErr(ctxt, XML_CHECK_NO_NAME, "Name is NULL");	    return;	}        if (xmlValidateName(name, 0)) {	    xmlDebugErr3(ctxt, XML_CHECK_NOT_NCNAME,			 "Name is not an NCName '%s'", (const char *) name);	}	if ((ctxt->dict != NULL) &&	    (!xmlDictOwns(ctxt->dict, name))) {	    xmlDebugErr3(ctxt, XML_CHECK_OUTSIDE_DICT,			 "Name is not from the document dictionnary '%s'",			 (const char *) name);	}    }}static voidxmlCtxtGenericNodeCheck(xmlDebugCtxtPtr ctxt, xmlNodePtr node) {    xmlDocPtr doc;    xmlDictPtr dict;    doc = node->doc;    if (node->parent == NULL)        xmlDebugErr(ctxt, XML_CHECK_NO_PARENT,	            "Node has no parent\n");    if (node->doc == NULL) {        xmlDebugErr(ctxt, XML_CHECK_NO_DOC,	            "Node has no doc\n");        dict = NULL;    } else {	dict = doc->dict;	if ((dict == NULL) && (ctxt->nodict == 0)) {#if 0            /* desactivated right now as it raises too many errors */	    if (doc->type == XML_DOCUMENT_NODE)		xmlDebugErr(ctxt, XML_CHECK_NO_DICT,			    "Document has no dictionnary\n");#endif	    ctxt->nodict = 1;	}	if (ctxt->doc == NULL)	    ctxt->doc = doc;	if (ctxt->dict == NULL) {	    ctxt->dict = dict;	}    }    if ((node->parent != NULL) && (node->doc != node->parent->doc) &&        (!xmlStrEqual(node->name, BAD_CAST "pseudoroot")))        xmlDebugErr(ctxt, XML_CHECK_WRONG_DOC,	            "Node doc differs from parent's one\n");    if (node->prev == NULL) {        if (node->type == XML_ATTRIBUTE_NODE) {	    if ((node->parent != NULL) &&	        (node != (xmlNodePtr) node->parent->properties))		xmlDebugErr(ctxt, XML_CHECK_NO_PREV,                    "Attr has no prev and not first of attr list\n");	                } else if ((node->parent != NULL) && (node->parent->children != node))	    xmlDebugErr(ctxt, XML_CHECK_NO_PREV,                    "Node has no prev and not first of parent list\n");    } else {        if (node->prev->next != node)	    xmlDebugErr(ctxt, XML_CHECK_WRONG_PREV,                        "Node prev->next : back link wrong\n");    }    if (node->next == NULL) {	if ((node->parent != NULL) && (node->type != XML_ATTRIBUTE_NODE) &&	    (node->parent->last != node))	    xmlDebugErr(ctxt, XML_CHECK_NO_NEXT,                    "Node has no next and not last of parent list\n");    } else {        if (node->next->prev != node)	    xmlDebugErr(ctxt, XML_CHECK_WRONG_NEXT,                    "Node next->prev : forward link wrong\n");        if (node->next->parent != node->parent)	    xmlDebugErr(ctxt, XML_CHECK_WRONG_PARENT,                    "Node next->prev : forward link wrong\n");    }    if (node->type == XML_ELEMENT_NODE) {        xmlNsPtr ns;	ns = node->nsDef;	while (ns != NULL) {	    xmlCtxtNsCheckScope(ctxt, node, ns);	    ns = ns->next;	}	if (node->ns != NULL)	    xmlCtxtNsCheckScope(ctxt, node, node->ns);    } else if (node->type == XML_ATTRIBUTE_NODE) {	if (node->ns != NULL)	    xmlCtxtNsCheckScope(ctxt, node, node->ns);    }    if ((node->type != XML_ELEMENT_NODE) &&	(node->type != XML_ATTRIBUTE_NODE) &&	(node->type != XML_ELEMENT_DECL) &&	(node->type != XML_ATTRIBUTE_DECL) &&	(node->type != XML_DTD_NODE) &&	(node->type != XML_ELEMENT_DECL) &&	(node->type != XML_HTML_DOCUMENT_NODE) &&	(node->type != XML_DOCUMENT_NODE)) {	if (node->content != NULL)	    xmlCtxtCheckString(ctxt, (const xmlChar *) node->content);    }    switch (node->type) {        case XML_ELEMENT_NODE:        case XML_ATTRIBUTE_NODE:	    xmlCtxtCheckName(ctxt, node->name);	    break;        case XML_TEXT_NODE:	    if ((node->name == xmlStringText) ||	        (node->name == xmlStringTextNoenc))		break;	    /* some case of entity substitution can lead to this */	    if ((ctxt->dict != NULL) &&	        (node->name == xmlDictLookup(ctxt->dict, BAD_CAST "nbktext",		                             7)))		break;	    xmlDebugErr3(ctxt, XML_CHECK_WRONG_NAME,			 "Text node has wrong name '%s'",			 (const char *) node->name);	    break;        case XML_COMMENT_NODE:	    if (node->name == xmlStringComment)		break;	    xmlDebugErr3(ctxt, XML_CHECK_WRONG_NAME,			 "Comment node has wrong name '%s'",			 (const char *) node->name);	    break;        case XML_PI_NODE:	    xmlCtxtCheckName(ctxt, node->name);	    break;        case XML_CDATA_SECTION_NODE:	    if (node->name == NULL)		break;	    xmlDebugErr3(ctxt, XML_CHECK_NAME_NOT_NULL,			 "CData section has non NULL name '%s'",			 (const char *) node->name);	    break;        case XML_ENTITY_REF_NODE:        case XML_ENTITY_NODE:        case XML_DOCUMENT_TYPE_NODE:        case XML_DOCUMENT_FRAG_NODE:        case XML_NOTATION_NODE:        case XML_DTD_NODE:        case XML_ELEMENT_DECL:        case XML_ATTRIBUTE_DECL:        case XML_ENTITY_DECL:        case XML_NAMESPACE_DECL:        case XML_XINCLUDE_START:        case XML_XINCLUDE_END:#ifdef LIBXML_DOCB_ENABLED        case XML_DOCB_DOCUMENT_NODE:#endif        case XML_DOCUMENT_NODE:        case XML_HTML_DOCUMENT_NODE:	    break;    }}static voidxmlCtxtDumpString(xmlDebugCtxtPtr ctxt, const xmlChar * str){    int i;    if (ctxt->check) {        return;    }    /* TODO: check UTF8 content of the string */    if (str == NULL) {        fprintf(ctxt->output, "(NULL)");        return;    }    for (i = 0; i < 40; i++)        if (str[i] == 0)            return;        else if (IS_BLANK_CH(str[i]))            fputc(' ', ctxt->output);        else if (str[i] >= 0x80)            fprintf(ctxt->output, "#%X", str[i]);        else            fputc(str[i], ctxt->output);    fprintf(ctxt->output, "...");}static voidxmlCtxtDumpDtdNode(xmlDebugCtxtPtr ctxt, xmlDtdPtr dtd){    xmlCtxtDumpSpaces(ctxt);    if (dtd == NULL) {        if (!ctxt->check)            fprintf(ctxt->output, "DTD node is NULL\n");        return;    }    if (dtd->type != XML_DTD_NODE) {	xmlDebugErr(ctxt, XML_CHECK_NOT_DTD,	            "Node is not a DTD");        return;    }    if (!ctxt->check) {        if (dtd->name != NULL)            fprintf(ctxt->output, "DTD(%s)", (char *) dtd->name);        else            fprintf(ctxt->output, "DTD");        if (dtd->ExternalID != NULL)            fprintf(ctxt->output, ", PUBLIC %s", (char *) dtd->ExternalID);        if (dtd->SystemID != NULL)            fprintf(ctxt->output, ", SYSTEM %s", (char *) dtd->SystemID);        fprintf(ctxt->output, "\n");    }    /*     * Do a bit of checking     */    xmlCtxtGenericNodeCheck(ctxt, (xmlNodePtr) dtd);}static voidxmlCtxtDumpAttrDecl(xmlDebugCtxtPtr ctxt, xmlAttributePtr attr){    xmlCtxtDumpSpaces(ctxt);

?? 快捷鍵說明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
成人涩涩免费视频| 久久美女高清视频| 欧美午夜视频网站| 欧美三级在线看| 欧洲视频一区二区| 在线亚洲欧美专区二区| 日本道免费精品一区二区三区| 99国产麻豆精品| 波多野结衣亚洲一区| 成人av高清在线| 色综合天天综合色综合av| 国产精品一区二区三区网站| 国产综合色精品一区二区三区| 日韩国产欧美三级| 蜜桃视频免费观看一区| 美女视频第一区二区三区免费观看网站| 丝瓜av网站精品一区二区| 视频一区国产视频| 久久99热这里只有精品| 国内精品视频666| 成人av在线网| 在线一区二区三区| 欧美一区二区三区在线看| 精品婷婷伊人一区三区三| 制服丝袜亚洲色图| 26uuu亚洲| 中文字幕亚洲一区二区av在线 | 欧美电影免费观看高清完整版| 日韩一区二区精品葵司在线| 欧美变态tickling挠脚心| 久久免费视频一区| 亚洲天天做日日做天天谢日日欢 | 亚洲永久精品大片| 久久精品国产亚洲一区二区三区| 久久99蜜桃精品| 成人午夜碰碰视频| 欧美日韩精品系列| 久久久蜜桃精品| 有码一区二区三区| 久久精品国产在热久久| hitomi一区二区三区精品| 欧美三级电影网站| 久久综合丝袜日本网| 一区二区三区日本| 国内久久精品视频| 欧美亚洲综合在线| 久久精品一二三| 亚洲夂夂婷婷色拍ww47| 久久精品99国产精品| 色综合一区二区| 精品国内二区三区| 一区二区三区欧美视频| 国产在线精品一区二区夜色 | 欧美在线看片a免费观看| 欧美电影精品一区二区| 亚洲色图视频网| 久久福利资源站| 91国偷自产一区二区三区观看| 日韩视频永久免费| 亚洲乱码国产乱码精品精98午夜 | 狠狠色2019综合网| 日本韩国精品一区二区在线观看| 日韩欧美一区二区视频| 亚洲女女做受ⅹxx高潮| 国产自产高清不卡| 欧美日韩亚洲综合在线 欧美亚洲特黄一级| 欧美精品一区二区蜜臀亚洲| 亚洲激情成人在线| 丁香另类激情小说| 日韩欧美一级二级| 亚洲第一久久影院| eeuss鲁片一区二区三区在线观看 eeuss鲁片一区二区三区在线看 | 成人激情校园春色| 日韩女优av电影| 亚洲成人综合在线| 91国偷自产一区二区三区观看 | 久久这里只精品最新地址| 亚洲女同ⅹxx女同tv| 国产99久久久国产精品潘金网站| 678五月天丁香亚洲综合网| 亚洲天堂网中文字| 成人伦理片在线| 久久久综合视频| 黑人精品欧美一区二区蜜桃| 欧美一区午夜视频在线观看| 亚洲韩国精品一区| 91麻豆国产在线观看| 欧美经典一区二区三区| 久久66热re国产| 日韩一区二区在线免费观看| 亚洲成a人v欧美综合天堂| 91麻豆精品视频| 亚洲欧美一区二区三区极速播放| 国产不卡高清在线观看视频| 欧美一区二区在线视频| 肉肉av福利一精品导航| 欧美日韩高清影院| 亚洲国产精品麻豆| 色噜噜狠狠色综合中国| 亚洲美女偷拍久久| 色综合天天综合网国产成人综合天| 国产精品免费视频一区| 粉嫩嫩av羞羞动漫久久久 | 日韩精品亚洲一区| 欧美亚一区二区| 亚洲午夜激情网页| 日韩你懂的在线播放| 日本不卡123| 日韩欧美一区二区免费| 久久99国产精品尤物| 欧美成人综合网站| 国产一区二区三区综合| 久久亚洲捆绑美女| 国产69精品久久99不卡| 1000精品久久久久久久久| 一本久久精品一区二区| 亚洲伊人色欲综合网| 欧美日韩不卡一区| 美国毛片一区二区| 久久综合色婷婷| 成人午夜大片免费观看| 亚洲日本在线a| 欧美日韩一区二区三区免费看| 亚洲成人在线网站| 精品福利在线导航| 成人性生交大片免费看中文| 综合久久国产九一剧情麻豆| 91久久线看在观草草青青| 天天色 色综合| 久久先锋影音av鲁色资源网| 丰满岳乱妇一区二区三区| 亚洲精品成人悠悠色影视| 欧美日精品一区视频| 极品少妇xxxx精品少妇| 中文字幕久久午夜不卡| 欧美在线观看禁18| 蜜臀av性久久久久蜜臀aⅴ| 中文字幕欧美日本乱码一线二线 | 国产精品无圣光一区二区| 色综合久久九月婷婷色综合| 日韩国产在线观看| 欧美激情在线看| 欧美中文字幕不卡| 国产在线视频精品一区| 一区二区在线观看不卡| 日韩精品中午字幕| 成人免费视频一区| 婷婷激情综合网| 中文字幕av不卡| 欧美一级淫片007| av在线不卡电影| 蜜芽一区二区三区| 中文字幕在线一区二区三区| 欧美人妇做爰xxxⅹ性高电影 | 在线精品视频小说1| 日本成人在线一区| 国产精品国产三级国产a| 欧美人伦禁忌dvd放荡欲情| 成人一区二区三区中文字幕| 午夜精品福利在线| 欧美国产激情二区三区| 制服视频三区第一页精品| 99视频在线精品| 久88久久88久久久| 一区二区欧美在线观看| 国产亚洲成av人在线观看导航| 欧美在线观看视频在线| 国产精品系列在线观看| 亚洲地区一二三色| 中文字幕综合网| 精品国产伦理网| 欧美日韩一区三区| 99国产精品久久久久| 韩国成人福利片在线播放| 亚洲一级片在线观看| 中文字幕制服丝袜成人av| 久久综合九色综合欧美98| 欧美日韩国产精选| 99re热视频这里只精品| 国产毛片精品一区| 免费看黄色91| 亚洲国产精品一区二区尤物区| 国产精品嫩草99a| 2023国产精品| 日韩欧美的一区| 欧美日韩www| 欧亚洲嫩模精品一区三区| 99久久精品国产麻豆演员表| 国产综合久久久久影院| 蜜桃一区二区三区四区| 日韩国产欧美在线观看| 午夜激情一区二区三区| 亚洲精品视频在线看| 中文字幕精品综合| 亚洲国产岛国毛片在线| 2023国产精品视频| 久久久一区二区三区捆绑**| 欧美一区二区三区小说| 欧美一区二区视频网站| 日韩小视频在线观看专区|