Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
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-cw
Commits
f81e0b03
Commit
f81e0b03
authored
Feb 18, 2005
by
Mike McCormack
Committed by
Alexandre Julliard
Feb 18, 2005
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Dump out more details on the target of a link.
parent
47f24896
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
51 additions
and
4 deletions
+51
-4
lnk.c
tools/winedump/lnk.c
+51
-4
No files found.
tools/winedump/lnk.c
View file @
f81e0b03
...
...
@@ -78,6 +78,14 @@ typedef struct _LOCATION_INFO
DWORD
dwFinalPathOfs
;
}
LOCATION_INFO
;
typedef
struct
_LOCAL_VOLUME_INFO
{
DWORD
dwSize
;
DWORD
dwType
;
DWORD
dwVolSerial
;
DWORD
dwVolLabelOfs
;
}
LOCAL_VOLUME_INFO
;
typedef
struct
lnk_string_tag
{
unsigned
short
size
;
union
{
...
...
@@ -221,20 +229,43 @@ static int dump_string(int fd, char *what, int unicode)
static
int
dump_location
(
int
fd
)
{
LOCATION_INFO
*
loc
;
char
*
p
;
loc
=
load_long_section
(
fd
);
if
(
!
loc
)
return
-
1
;
p
=
(
char
*
)
loc
;
printf
(
"Location
\n
"
);
printf
(
"--------
\n\n
"
);
printf
(
"Total size = %ld
\n
"
,
loc
->
dwTotalSize
);
printf
(
"Header size = %ld
\n
"
,
loc
->
dwHeaderSize
);
printf
(
"Flags = %08lx
\n
"
,
loc
->
dwFlags
);
printf
(
"Volume ofs = %08lx
\n
"
,
loc
->
dwVolTableOfs
);
printf
(
"LocalPath ofs = %08lx
\n
"
,
loc
->
dwLocalPathOfs
);
/* dump out information about the volume the link points to */
printf
(
"Volume ofs = %08lx "
,
loc
->
dwVolTableOfs
);
if
(
loc
->
dwVolTableOfs
&&
(
loc
->
dwVolTableOfs
<
loc
->
dwTotalSize
))
{
LOCAL_VOLUME_INFO
*
vol
=
(
LOCAL_VOLUME_INFO
*
)
&
p
[
loc
->
dwVolTableOfs
];
printf
(
"size %ld type %ld serial %08lx label %ld "
,
vol
->
dwSize
,
vol
->
dwType
,
vol
->
dwVolSerial
,
vol
->
dwVolLabelOfs
);
if
(
vol
->
dwVolLabelOfs
)
printf
(
"(
\"
%s
\"
)"
,
&
p
[
vol
->
dwVolLabelOfs
]);
}
printf
(
"
\n
"
);
/* dump out the path the link points to */
printf
(
"LocalPath ofs = %08lx "
,
loc
->
dwLocalPathOfs
);
if
(
loc
->
dwLocalPathOfs
&&
(
loc
->
dwLocalPathOfs
<
loc
->
dwTotalSize
)
)
printf
(
"(
\"
%s
\"
)"
,
&
p
[
loc
->
dwLocalPathOfs
]);
printf
(
"
\n
"
);
printf
(
"Net Path ofs = %08lx
\n
"
,
loc
->
dwNetworkVolTableOfs
);
printf
(
"Final Path = %08lx
\n
"
,
loc
->
dwFinalPathOfs
);
printf
(
"Final Path = %08lx "
,
loc
->
dwFinalPathOfs
);
if
(
loc
->
dwFinalPathOfs
&&
(
loc
->
dwFinalPathOfs
<
loc
->
dwTotalSize
)
)
printf
(
"(
\"
%s
\"
)"
,
&
p
[
loc
->
dwFinalPathOfs
]);
printf
(
"
\n
"
);
printf
(
"
\n
"
);
free
(
loc
);
...
...
@@ -274,7 +305,23 @@ static int dump_lnk_fd(int fd)
printf
(
"------
\n\n
"
);
printf
(
"Size: %04lx
\n
"
,
hdr
->
dwSize
);
printf
(
"GUID: %s
\n
"
,
guid
);
printf
(
"Flags: %04lx
\n
"
,
hdr
->
dwFlags
);
/* dump out all the flags */
printf
(
"Flags: %04lx ( "
,
hdr
->
dwFlags
);
#define FLAG(x) if(hdr->dwFlags & SCF_##x) printf("%s ",#x);
FLAG
(
PIDL
)
FLAG
(
LOCATION
)
FLAG
(
DESCRIPTION
)
FLAG
(
RELATIVE
)
FLAG
(
WORKDIR
)
FLAG
(
ARGS
)
FLAG
(
CUSTOMICON
)
FLAG
(
UNICODE
)
FLAG
(
PRODUCT
)
FLAG
(
COMPONENT
)
#undef FLAG
printf
(
")
\n
"
);
printf
(
"Length: %04lx
\n
"
,
hdr
->
dwFileLength
);
printf
(
"
\n
"
);
...
...
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