=?UTF-8?Q?Andr=C3=A9=20Hentschel=20?=: dnsapi: Use internal name_skip function.

Alexandre Julliard julliard at winehq.org
Wed Sep 7 12:35:29 CDT 2011


Module: wine
Branch: master
Commit: 9e50294f2391a63d9b3819f7c0f7d40e8aaf61a2
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=9e50294f2391a63d9b3819f7c0f7d40e8aaf61a2

Author: André Hentschel <nerv at dawncrow.de>
Date:   Wed Sep  7 01:41:39 2011 +0200

dnsapi: Use internal name_skip function.

---

 dlls/dnsapi/ns_parse.c |   12 ++++++++----
 1 files changed, 8 insertions(+), 4 deletions(-)

diff --git a/dlls/dnsapi/ns_parse.c b/dlls/dnsapi/ns_parse.c
index bfb83c2..df4933a 100644
--- a/dlls/dnsapi/ns_parse.c
+++ b/dlls/dnsapi/ns_parse.c
@@ -32,9 +32,14 @@
 #ifdef HAVE_RESOLV_H
 # include <resolv.h>
 #endif
+#include <stdarg.h>
 #include <string.h>
 
 #include "windef.h"
+#include "winbase.h"
+#include "winnls.h"
+
+#include "dnsapi.h"
 
 /* Forward. */
 
@@ -75,12 +80,11 @@ dns_ns_skiprr(const u_char *ptr, const u_char *eom, ns_sect section, int count)
 	const u_char *optr = ptr;
 
 	while (count-- > 0) {
-		int b, rdlength;
+		int rdlength;
 
-		b = dn_skipname(ptr, eom);
-		if (b < 0)
+		if (dns_ns_name_skip(&ptr, eom) < 0)
 			RETERR(EMSGSIZE);
-		ptr += b/*Name*/ + NS_INT16SZ/*Type*/ + NS_INT16SZ/*Class*/;
+		ptr += NS_INT16SZ/*Type*/ + NS_INT16SZ/*Class*/;
 		if (section != ns_s_qd) {
 			if (ptr + NS_INT32SZ + NS_INT16SZ > eom)
 				RETERR(EMSGSIZE);




More information about the wine-cvs mailing list