diff --git a/ChangeLog b/ChangeLog index 23cf3c26..406827e2 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +Tue Jul 17 16:04:36 EDT 2001 Daniel Veillard + + * SAX.c xmlIO.c: cleaned up some warning on the Alpha + Mon Jul 16 06:32:44 CEST 2001 Thomas Broyer * include/libxml/xpath{,Internals}.h xpath.c: added a more diff --git a/SAX.c b/SAX.c index 73e04b84..425b374e 100644 --- a/SAX.c +++ b/SAX.c @@ -967,7 +967,7 @@ startElement(void *ctx, const xmlChar *fullname, const xmlChar **atts) } ctxt->nodemem = -1; if (ctxt->input != NULL) - ret->content = (void *) ctxt->input->line; + ret->content = (void *) (long) ctxt->input->line; /* * We are parsing a new node. diff --git a/config.h.in b/config.h.in index 07ded072..bf54bc04 100644 --- a/config.h.in +++ b/config.h.in @@ -91,9 +91,6 @@ /* Define if you have the header file. */ #undef HAVE_DIRENT_H -/* Define if you have the header file. */ -#undef HAVE_DLFCN_H - /* Define if you have the header file. */ #undef HAVE_ERRNO_H diff --git a/include/libxml/xpathInternals.h b/include/libxml/xpathInternals.h index 05f843c0..1574e786 100644 --- a/include/libxml/xpathInternals.h +++ b/include/libxml/xpathInternals.h @@ -27,10 +27,10 @@ extern "C" { * * ************************************************************************/ - /** - * Many of these macros may later turn into functions. They - * shouldn't be used in #ifdef's preprocessor instructions. - */ +/** + * Many of these macros may later turn into functions. They + * shouldn't be used in #ifdef's preprocessor instructions. + */ /** * xmlXPathSetError: * @ctxt: an XPath parser context @@ -41,6 +41,7 @@ extern "C" { #define xmlXPathSetError(ctxt, err) \ { xmlXPatherror((ctxt), __FILE__, __LINE__, (err)); \ (ctxt)->error = (err); } + /** * xmlXPathSetArityError: * @ctxt: an XPath parser context @@ -49,6 +50,7 @@ extern "C" { */ #define xmlXPathSetArityError(ctxt) \ xmlXPathSetError((ctxt), XPATH_INVALID_ARITY) + /** * xmlXPathSetTypeError: * @ctxt: an XPath parser context @@ -57,6 +59,7 @@ extern "C" { */ #define xmlXPathSetTypeError(ctxt) \ xmlXPathSetError((ctxt), XPATH_INVALID_TYPE) + /** * xmlXPathGetError: * @ctxt: an XPath parser context @@ -64,6 +67,7 @@ extern "C" { * Returns the context error */ #define xmlXPathGetError(ctxt) ((ctxt)->error) + /** * xmlXPathCheckError: * @ctxt: an XPath parser context @@ -79,6 +83,7 @@ extern "C" { * Returns the context document */ #define xmlXPathGetDocument(ctxt) ((ctxt)->context->doc) + /** * xmlXPathGetContextNode: * @ctxt: an XPath parser context @@ -102,6 +107,7 @@ void * xmlXPathPopExternal (xmlXPathParserContextPtr ctxt); */ #define xmlXPathReturnBoolean(ctxt, val) \ valuePush((ctxt), xmlXPathNewBoolean(val)) + /** * xmlXPathReturnTrue: * @ctxt: an XPath parser context @@ -109,6 +115,7 @@ void * xmlXPathPopExternal (xmlXPathParserContextPtr ctxt); * Pushes true on the context stack */ #define xmlXPathReturnTrue(ctxt) xmlXPathReturnBoolean((ctxt), 1) + /** * xmlXPathReturnFalse: * @ctxt: an XPath parser context @@ -116,6 +123,7 @@ void * xmlXPathPopExternal (xmlXPathParserContextPtr ctxt); * Pushes false on the context stack */ #define xmlXPathReturnFalse(ctxt) xmlXPathReturnBoolean((ctxt), 0) + /** * xmlXPathReturnNumber: * @ctxt: an XPath parser context @@ -125,6 +133,7 @@ void * xmlXPathPopExternal (xmlXPathParserContextPtr ctxt); */ #define xmlXPathReturnNumber(ctxt, val) \ valuePush((ctxt), xmlXPathNewFloat(val)) + /** * xmlXPathReturnString: * @ctxt: an XPath parser context @@ -134,6 +143,7 @@ void * xmlXPathPopExternal (xmlXPathParserContextPtr ctxt); */ #define xmlXPathReturnString(ctxt, str) \ valuePush((ctxt), xmlXPathWrapString(str)) + /** * xmlXPathReturnEmptyString: * @ctxt: an XPath parser context @@ -142,6 +152,7 @@ void * xmlXPathPopExternal (xmlXPathParserContextPtr ctxt); */ #define xmlXPathReturnEmptyString(ctxt) \ valuePush((ctxt), xmlXPathNewCString("")) + /** * xmlXPathReturnNodeSet: * @ctxt: an XPath parser context @@ -151,6 +162,7 @@ void * xmlXPathPopExternal (xmlXPathParserContextPtr ctxt); */ #define xmlXPathReturnNodeSet(ctxt, ns) \ valuePush((ctxt), xmlXPathWrapNodeSet(ns)) + /** * xmlXPathReturnEmptyNodeSet: * @ctxt: an XPath parser context @@ -159,6 +171,7 @@ void * xmlXPathPopExternal (xmlXPathParserContextPtr ctxt); */ #define xmlXPathReturnEmptyNodeSet(ctxt, ns) \ valuePush((ctxt), xmlXPathNewNodeSet(NULL)) + /** * xmlXPathReturnExternal: * @ctxt: an XPath parser context @@ -189,11 +202,6 @@ void * xmlXPathPopExternal (xmlXPathParserContextPtr ctxt); #define xmlXPathEmptyNodeSet(ns) \ { while ((ns)->nodeNr > 0) (ns)->nodeTab[(ns)->nodeNr--] = NULL; } - /** - * These macros shouldn't be used anymore. Prefer above functions - * and macros. - */ - /** * CHECK_ERROR: * diff --git a/xmlIO.c b/xmlIO.c index db245d05..a7269c74 100644 --- a/xmlIO.c +++ b/xmlIO.c @@ -174,7 +174,7 @@ xmlNop(void) { */ static int xmlFdRead (void * context, char * buffer, int len) { - return(read((int) context, &buffer[0], len)); + return(read((int) (long) context, &buffer[0], len)); } /** @@ -189,7 +189,7 @@ xmlFdRead (void * context, char * buffer, int len) { */ static int xmlFdWrite (void * context, const char * buffer, int len) { - return(write((int) context, &buffer[0], len)); + return(write((int) (long) context, &buffer[0], len)); } /** @@ -200,7 +200,7 @@ xmlFdWrite (void * context, const char * buffer, int len) { */ static void xmlFdClose (void * context) { - close((int) context); + close((int) (long) context); } /** @@ -1088,7 +1088,7 @@ xmlParserInputBufferCreateFd(int fd, xmlCharEncoding enc) { ret = xmlAllocParserInputBuffer(enc); if (ret != NULL) { - ret->context = (void *) fd; + ret->context = (void *) (long) fd; ret->readcallback = xmlFdRead; ret->closecallback = xmlFdClose; } @@ -1143,7 +1143,7 @@ xmlOutputBufferCreateFd(int fd, xmlCharEncodingHandlerPtr encoder) { ret = xmlAllocOutputBuffer(encoder); if (ret != NULL) { - ret->context = (void *) fd; + ret->context = (void *) (long) fd; ret->writecallback = xmlFdWrite; ret->closecallback = xmlFdClose; }