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
59a50245
Commit
59a50245
authored
Feb 04, 2009
by
Andrew Talbot
Committed by
Alexandre Julliard
Feb 05, 2009
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
itss: Remove unused function.
parent
61292cfc
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
0 additions
and
114 deletions
+0
-114
chm_lib.c
dlls/itss/chm_lib.c
+0
-109
chm_lib.h
dlls/itss/chm_lib.h
+0
-5
No files found.
dlls/itss/chm_lib.c
View file @
59a50245
...
...
@@ -1373,115 +1373,6 @@ LONGINT64 chm_retrieve_object(struct chmFile *h,
}
}
/* enumerate the objects in the .chm archive */
int
chm_enumerate
(
struct
chmFile
*
h
,
int
what
,
CHM_ENUMERATOR
e
,
void
*
context
)
{
Int32
curPage
;
/* buffer to hold whatever page we're looking at */
UChar
*
page_buf
=
HeapAlloc
(
GetProcessHeap
(),
0
,
h
->
block_len
);
struct
chmPmglHeader
header
;
UChar
*
end
;
UChar
*
cur
;
unsigned
int
lenRemain
;
UInt64
ui_path_len
;
/* the current ui */
struct
chmUnitInfo
ui
;
int
flag
;
/* starting page */
curPage
=
h
->
index_head
;
/* until we have either returned or given up */
while
(
curPage
!=
-
1
)
{
/* try to fetch the index page */
if
(
_chm_fetch_bytes
(
h
,
page_buf
,
h
->
dir_offset
+
(
UInt64
)
curPage
*
h
->
block_len
,
h
->
block_len
)
!=
h
->
block_len
)
{
HeapFree
(
GetProcessHeap
(),
0
,
page_buf
);
return
0
;
}
/* figure out start and end for this page */
cur
=
page_buf
;
lenRemain
=
_CHM_PMGL_LEN
;
if
(
!
_unmarshal_pmgl_header
(
&
cur
,
&
lenRemain
,
&
header
))
{
HeapFree
(
GetProcessHeap
(),
0
,
page_buf
);
return
0
;
}
end
=
page_buf
+
h
->
block_len
-
(
header
.
free_space
);
/* loop over this page */
while
(
cur
<
end
)
{
if
(
!
_chm_parse_PMGL_entry
(
&
cur
,
&
ui
))
{
HeapFree
(
GetProcessHeap
(),
0
,
page_buf
);
return
0
;
}
/* get the length of the path */
ui_path_len
=
strlenW
(
ui
.
path
)
-
1
;
/* check for DIRS */
if
(
ui
.
path
[
ui_path_len
]
==
'/'
&&
!
(
what
&
CHM_ENUMERATE_DIRS
))
continue
;
/* check for FILES */
if
(
ui
.
path
[
ui_path_len
]
!=
'/'
&&
!
(
what
&
CHM_ENUMERATE_FILES
))
continue
;
/* check for NORMAL vs. META */
if
(
ui
.
path
[
0
]
==
'/'
)
{
/* check for NORMAL vs. SPECIAL */
if
(
ui
.
path
[
1
]
==
'#'
||
ui
.
path
[
1
]
==
'$'
)
flag
=
CHM_ENUMERATE_SPECIAL
;
else
flag
=
CHM_ENUMERATE_NORMAL
;
}
else
flag
=
CHM_ENUMERATE_META
;
if
(
!
(
what
&
flag
))
continue
;
/* call the enumerator */
{
int
status
=
(
*
e
)(
h
,
&
ui
,
context
);
switch
(
status
)
{
case
CHM_ENUMERATOR_FAILURE
:
HeapFree
(
GetProcessHeap
(),
0
,
page_buf
);
return
0
;
case
CHM_ENUMERATOR_CONTINUE
:
break
;
case
CHM_ENUMERATOR_SUCCESS
:
HeapFree
(
GetProcessHeap
(),
0
,
page_buf
);
return
1
;
default:
break
;
}
}
}
/* advance to next page */
curPage
=
header
.
block_next
;
}
HeapFree
(
GetProcessHeap
(),
0
,
page_buf
);
return
1
;
}
int
chm_enumerate_dir
(
struct
chmFile
*
h
,
const
WCHAR
*
prefix
,
int
what
,
...
...
dlls/itss/chm_lib.h
View file @
59a50245
...
...
@@ -104,11 +104,6 @@ typedef int (*CHM_ENUMERATOR)(struct chmFile *h,
#define CHM_ENUMERATOR_FAILURE (0)
#define CHM_ENUMERATOR_CONTINUE (1)
#define CHM_ENUMERATOR_SUCCESS (2)
int
chm_enumerate
(
struct
chmFile
*
h
,
int
what
,
CHM_ENUMERATOR
e
,
void
*
context
);
int
chm_enumerate_dir
(
struct
chmFile
*
h
,
const
WCHAR
*
prefix
,
int
what
,
...
...
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