fixed problem in xmlTextWriterVSprintf caused by misuse of vsnprintf added

* xmlwriter.c: fixed problem in xmlTextWriterVSprintf caused by
  misuse of vsnprintf
* configure.in, config.h.in: added a configuration check for
  va_copy and added a define for VA_COPY for xmlwriter.c fix
* parser.c: fixed problem with CRLF split between chunks (bug
  #319279) (fix provided by Brion Vibber)
diff --git a/parser.c b/parser.c
index aeb8ab3..459c5e9 100644
--- a/parser.c
+++ b/parser.c
@@ -3549,6 +3549,8 @@
 		    ctxt->input->line++; ctxt->input->col = 1;
 		    continue; /* while */
 		}
+		if (!*in)	/* if end of current chunk return */
+		    return;
 		in--;
 	    }
 	    if (*in == '<') {