Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
8cae5c23
Commit
8cae5c23
authored
Apr 20, 2011
by
Dylan Smith
Committed by
Alexandre Julliard
Apr 21, 2011
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
d3dxof: GetName can be used to just get the name length.
parent
10fbf5f5
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
25 additions
and
5 deletions
+25
-5
d3dxof.c
dlls/d3dxof/d3dxof.c
+25
-5
No files found.
dlls/d3dxof/d3dxof.c
View file @
8cae5c23
...
...
@@ -728,13 +728,23 @@ static HRESULT WINAPI IDirectXFileDataImpl_GetName(IDirectXFileData* iface, LPST
{
IDirectXFileDataImpl
*
This
=
(
IDirectXFileDataImpl
*
)
iface
;
DWORD
len
;
TRACE
(
"(%p/%p)->(%p,%p)
\n
"
,
This
,
iface
,
pstrNameBuf
,
pdwBufLen
);
if
(
!
p
strNameBuf
)
if
(
!
p
dwBufLen
)
return
DXFILEERR_BADVALUE
;
strcpy
(
pstrNameBuf
,
This
->
pobj
->
name
);
len
=
strlen
(
This
->
pobj
->
name
);
if
(
len
)
len
++
;
if
(
pstrNameBuf
)
{
if
(
*
pdwBufLen
<
len
)
return
DXFILEERR_BADVALUE
;
CopyMemory
(
pstrNameBuf
,
This
->
pobj
->
name
,
len
);
}
*
pdwBufLen
=
len
;
return
DXFILE_OK
;
}
...
...
@@ -962,15 +972,25 @@ static ULONG WINAPI IDirectXFileDataReferenceImpl_Release(IDirectXFileDataRefere
static
HRESULT
WINAPI
IDirectXFileDataReferenceImpl_GetName
(
IDirectXFileDataReference
*
iface
,
LPSTR
pstrNameBuf
,
LPDWORD
pdwBufLen
)
{
IDirectXFileDataReferenceImpl
*
This
=
(
IDirectXFileDataReferenceImpl
*
)
iface
;
DWORD
len
;
TRACE
(
"(%p/%p)->(%p,%p)
\n
"
,
This
,
iface
,
pstrNameBuf
,
pdwBufLen
);
if
(
!
p
strNameBuf
)
if
(
!
p
dwBufLen
)
return
DXFILEERR_BADVALUE
;
strcpy
(
pstrNameBuf
,
This
->
ptarget
->
name
);
len
=
strlen
(
This
->
ptarget
->
name
);
if
(
len
)
len
++
;
return
DXFILEERR_BADVALUE
;
if
(
pstrNameBuf
)
{
if
(
*
pdwBufLen
<
len
)
return
DXFILEERR_BADVALUE
;
CopyMemory
(
pstrNameBuf
,
This
->
ptarget
->
name
,
len
);
}
*
pdwBufLen
=
len
;
return
DXFILE_OK
;
}
static
HRESULT
WINAPI
IDirectXFileDataReferenceImpl_GetId
(
IDirectXFileDataReference
*
iface
,
LPGUID
pGuid
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment