Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
wine
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Package registry
Container Registry
Model registry
Operate
Terraform modules
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Yoann Laissus
wine
Commits
f9e4e9df
Commit
f9e4e9df
authored
23 years ago
by
Chris Green
Committed by
Alexandre Julliard
23 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Get the correct label on iso9660 mixed-mode cds.
parent
00bd7998
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
misc/cdrom.c
+19
-8
19 additions, 8 deletions
misc/cdrom.c
with
19 additions
and
8 deletions
misc/cdrom.c
+
19
−
8
View file @
f9e4e9df
...
...
@@ -612,21 +612,35 @@ int CDROM_Reset(WINE_CDAUDIO* wcda, int parentdev)
return
ret
;
}
/**************************************************************************
* CDROM_Data_FindBestVoldesc [internal]
*/
WORD
CDROM_Data_FindBestVoldesc
(
int
fd
)
{
BYTE
cur_vd_type
,
max_vd_type
=
0
;
unsigned
int
offs
,
best_offs
=
0
;
unsigned
int
offs
,
best_offs
=
0
,
extra_offs
=
0
;
char
sig
[
3
];
for
(
offs
=
0x8000
;
offs
<=
0x9800
;
offs
+=
0x800
)
{
lseek
(
fd
,
offs
,
SEEK_SET
);
/* if 'CDROM' occurs at position 8, this is a pre-iso9660 cd, and
* the volume label is displaced forward by 8
*/
lseek
(
fd
,
offs
+
11
,
SEEK_SET
);
/* check for non-ISO9660 signature */
read
(
fd
,
&
sig
,
3
);
if
((
sig
[
0
]
==
'R'
)
&&
(
sig
[
1
]
==
'O'
)
&&
(
sig
[
2
]
==
'M'
))
{
extra_offs
=
8
;
}
lseek
(
fd
,
offs
+
extra_offs
,
SEEK_SET
);
read
(
fd
,
&
cur_vd_type
,
1
);
if
(
cur_vd_type
==
0xff
)
/* voldesc set terminator */
break
;
if
(
cur_vd_type
>
max_vd_type
)
{
max_vd_type
=
cur_vd_type
;
best_offs
=
offs
;
best_offs
=
offs
+
extra_offs
;
}
}
return
best_offs
;
...
...
@@ -858,6 +872,8 @@ DWORD CDROM_GetLabel(int drive, char *label)
if
(
!
cdname
)
cdname
=
"XA 2.1"
;
case
CDS_XA_2_2
:
if
(
!
cdname
)
cdname
=
"XA 2.2"
;
case
CDS_MIXED
:
if
(
!
cdname
)
cdname
=
"Mixed mode"
;
case
-
1
:
if
(
!
cdname
)
cdname
=
"Unknown/ISO file"
;
...
...
@@ -867,11 +883,6 @@ DWORD CDROM_GetLabel(int drive, char *label)
ret
=
0
;
break
;
case
CDS_MIXED
:
cdname
=
"Mixed mode"
;
FIXME
(
"Need to get the label of a mixed mode CD: not implemented yet !
\n
"
);
/* fall through */
case
CDS_NO_INFO
:
if
(
!
cdname
)
cdname
=
"No_info"
;
ret
=
0
;
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment