mirror of
https://github.com/darlinghq/darling-libxml2.git
synced 2024-12-15 00:08:29 +00:00
cleaned up some warning on the Alpha Daniel
* SAX.c xmlIO.c: cleaned up some warning on the Alpha Daniel
This commit is contained in:
parent
f06a3d8b53
commit
8fcc494e64
@ -1,3 +1,7 @@
|
||||
Tue Jul 17 16:04:36 EDT 2001 Daniel Veillard <Daniel.Veillard@imag.fr>
|
||||
|
||||
* SAX.c xmlIO.c: cleaned up some warning on the Alpha
|
||||
|
||||
Mon Jul 16 06:32:44 CEST 2001 Thomas Broyer <tbroyer@ltgt.net>
|
||||
|
||||
* include/libxml/xpath{,Internals}.h xpath.c: added a more
|
||||
|
2
SAX.c
2
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.
|
||||
|
@ -91,9 +91,6 @@
|
||||
/* Define if you have the <dirent.h> header file. */
|
||||
#undef HAVE_DIRENT_H
|
||||
|
||||
/* Define if you have the <dlfcn.h> header file. */
|
||||
#undef HAVE_DLFCN_H
|
||||
|
||||
/* Define if you have the <errno.h> header file. */
|
||||
#undef HAVE_ERRNO_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:
|
||||
*
|
||||
|
10
xmlIO.c
10
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;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user