[1/2] msxml3: Implement getLocalName() for IMXAttributes
Nikolay Sivov
nsivov at codeweavers.com
Tue Apr 24 03:11:41 CDT 2012
Implement getLocalName() for IMXAttributes
-------------- next part --------------
>From 1bb6472cd58eb6e9cca0fa771d2ef6aee1f56d9b Mon Sep 17 00:00:00 2001
From: Nikolay Sivov <nsivov at codeweavers.com>
Date: Tue, 24 Apr 2012 11:30:24 +0400
Subject: [PATCH 1/2] Implement getLocalName() for IMXAttributes
---
dlls/msxml3/mxwriter.c | 16 ++++++++++++----
1 files changed, 12 insertions(+), 4 deletions(-)
diff --git a/dlls/msxml3/mxwriter.c b/dlls/msxml3/mxwriter.c
index e4224ed..48d9f8d 100644
--- a/dlls/msxml3/mxwriter.c
+++ b/dlls/msxml3/mxwriter.c
@@ -1795,12 +1795,20 @@ static HRESULT WINAPI SAXAttributes_getURI(ISAXAttributes *iface, int nIndex, co
return E_NOTIMPL;
}
-static HRESULT WINAPI SAXAttributes_getLocalName(ISAXAttributes *iface, int nIndex, const WCHAR **localName,
- int *length)
+static HRESULT WINAPI SAXAttributes_getLocalName(ISAXAttributes *iface, int index, const WCHAR **name,
+ int *len)
{
mxattributes *This = impl_from_ISAXAttributes( iface );
- FIXME("(%p)->(%d %p %p): stub\n", This, nIndex, localName, length);
- return E_NOTIMPL;
+
+ TRACE("(%p)->(%d %p %p)\n", This, index, name, len);
+
+ if (index >= This->length || index < 0) return E_INVALIDARG;
+ if (!name || !len) return E_POINTER;
+
+ *len = SysStringLen(This->attr[index].local);
+ *name = This->attr[index].local;
+
+ return S_OK;
}
static HRESULT WINAPI SAXAttributes_getQName(ISAXAttributes *iface, int index, const WCHAR **qname, int *length)
--
1.5.6.5
More information about the wine-patches
mailing list