Commit graph

4343 commits

Author SHA1 Message Date
sluicebox
cdb79983aa
COMMON: Add INIFile::requireKeyValueDelimiter() 2023-12-14 16:49:28 +01:00
Eugene Sandulenko
17b85a946c
Revert "COMMON: Add a mode to the INI parser to ignore garbage in some files"
This reverts commit c69e98bad5.
2023-12-14 16:45:02 +01:00
never
c69e98bad5
COMMON: Add a mode to the INI parser to ignore garbage in some files 2023-12-11 15:08:52 +01:00
sluicebox
a5ef00a514 COMMON: Fix StuffIt memory leak. PVS-Studio V773 2023-12-07 19:41:28 -08:00
Misty De Meo
6b8d8c3f4e COMMON: cue - fix implicit indices
If index 0 isn't specified, we need to be able to distinguish between
"this index has a value of 0" and "this index is missing". We now set
missing indices to -1 to help distinguish, and guard against using
a non-existent index in cases where it's not there.

Also fixes an off-by-one error in getTrackAtFrame exposed by this fix.
2023-12-03 20:58:36 +01:00
Thierry Crozat
c748d1fd6d COMMON: Add ConfMan function to know if a default is set for a key 2023-12-03 16:17:32 +00:00
Misty De Meo
e8e5263bb1 COMMON: avoid inserting null tracks 2023-11-30 01:41:10 +01:00
Misty De Meo
1492866d59 COMMON: reorient cue around tracks 2023-11-30 01:41:10 +01:00
Eugene Sandulenko
097d819236
Revert "COMMON: Fixed order of loading zip packs"
This reverts commit 57c87b4b50.

It appears to be incorrect and breaks the icon updates.
2023-11-21 17:24:20 +01:00
Le Philousophe
a700883e6f JANITORIAL: Fix spaces vs tab mismatch 2023-11-19 11:35:35 +01:00
Eugene Sandulenko
0938e8e499
COMMON: Allow all symbols when ncluding FriBiDi headers.
This fixes compilation on some systems. Bug #13485
2023-11-19 02:30:25 +01:00
Matthew Duggan
e3f4117535 COMMON: Avoid Quicktime parsing crash on early EOF
In parseStream, atom.size is initailized to uint32 max.  If the loop in
readDefault then never executes because the stream has hit EOF, that size is
passed as-is to seek.  This can cause a crash eg in SeekableSubReadStream
because of an int overflow.

Change readDefault to return an error in a few places if we have hit eof before
a valid atom has been read.  It's ok not to do the seek in this case.
2023-11-18 21:03:02 +01:00
Matthew Jimenez
5f75054fde COMMON: Skip possible UTF-8 BOM when reading INI files 2023-11-18 20:20:56 +01:00
Eugene Sandulenko
57c87b4b50
COMMON: Fixed order of loading zip packs
It appears that the subsequent packages actually override previous ones
2023-11-10 23:43:58 +01:00
Kaloyan Chehlarski
f5bed36b54 COMMON: Fix edge case in InstallShield file extraction
It is possible for a file table to contain multiple entries for
the same file, each with a different volume. This is valid,
and means that the file can be extracted from multiple .cab
files.
However, sometimes the header can report a file as existing
in multiple volumes despite it not actually being present in
all of them. The previous policy when encountering
duplicate entries was to just overwrite, which effectively
resulted in us keeping the last encountered entry, which
would be for the highest volume id. However, when an
erroneous entry mentioned above was encountered,
extraction would fail.
This commit makes it so we now keep the entry with the
lowest volume id, and discard the rest.
2023-11-09 22:18:11 +02:00
Cameron Cawley
953772ba99 COMMON: Rename memset2/4/8 to memset16/32/64 2023-11-06 13:40:38 +02:00
Cameron Cawley
ac2d99ee9b COMMON: Add variants of memset for 16-bit, 32-bit and 64-bit values 2023-11-06 13:40:38 +02:00
Eugene Sandulenko
0644ad9e9a
COMMON: Print out opened file path on debug level 5
This potentially let us narrow down reports where users have stray files
in their paths like extrapath.
2023-11-02 22:12:58 +01:00
Kaloyan Chehlarski
1a08bcc08f ARCHIVE: Allow creating InstallShieldV3 archives with FSNode 2023-11-02 18:20:44 +01:00
Kaloyan Chehlarski
3829b41235 COMMON: Allow creating InstallShield archive with FSNode
This is needed for cases where SearchMan is not applicable
(e.g. during detection)
2023-11-02 18:20:44 +01:00
sluicebox
95f8e1404f COMMON: Use logical Or in SubReadStream::eos. PVS-Studio V792 2023-10-31 14:20:30 -07:00
Eugene Sandulenko
6683a75954
COMMON: FORMATS: Pass image extensions to the user callbacks in Markdown 2023-10-31 01:58:55 +01:00
Eugene Sandulenko
5a30cb60aa
COMMON: FORMATS: Extend Markdown images with {} attributes 2023-10-31 01:57:57 +01:00
sluicebox
db11ff30fa COMMON: Fix MacResManager memory leak. PVS-Studio V773 2023-10-29 18:16:23 -07:00
Cameron Cawley
bcc9259382 BACKENDS: Report if the backend supports cursors with alpha channels 2023-10-29 02:02:11 +02:00
Kaloyan Chehlarski
ab784bdd8b COMMON: Allow extraction of empty files from InstallShield cabs
It is not uncommon for an InstallShield cab to have file
entries with a size of 0; this commit makes sure that trying to
extract such a file won't result in a warning, and won't
cause a crash when calling dumpArchive() on the containing
cabinet file.
2023-10-28 16:19:34 +03:00
sluicebox
43a3aad456 COMMON: Remove unused field from Gentee Installer code
Fixes unused private field warning
2023-10-27 20:45:09 -07:00
Aditya
a5b3353022 ALL: Decrease header dependency for gui_options.h
Now the number of times the header file gui_options.h
is added is much smaller.
2023-10-27 01:16:32 +02:00
Kaloyan Chehlarski
fc0988fdfc COMMON: Allow IFF containers to have custom header IDs
The IFF format used in the Nancy Drew engine uses a
non-standard id that reads DATA instead of FORM, though
the rest of the format is identical. This commit allows such
nonstandard ids to be used without needing to massage the
data first.
2023-10-26 19:46:32 +03:00
D G Turner
781fabac28 COMMON: Fix Signed vs. Unsigned GCC Compiler Warning in Cue Sheet Parser
This should now be fixed irrespective of whether size_t is signed or not.
2023-10-15 20:37:16 +01:00
Eugene Sandulenko
dea1412b3b COMMON: Fix warnings 2023-10-12 23:54:48 +02:00
Eugene Sandulenko
587d770786 COMMON: Shortened constant names in CueSheet class 2023-10-12 23:54:48 +02:00
Eugene Sandulenko
3e32fd3776 COMMON: Added another constructor for CueSheet 2023-10-12 23:54:48 +02:00
Eugene Sandulenko
12cf6c9988 COMMON: Improve debug output in CueSheet 2023-10-12 23:54:48 +02:00
Eugene Sandulenko
462870c64d COMMON: Lookup track sector sizes for CueSheet 2023-10-12 23:54:48 +02:00
Eugene Sandulenko
c5a71570f0 COMMON: Added parsing of catalog and Cue track flags 2023-10-12 23:54:48 +02:00
Eugene Sandulenko
824d28ff5e COMMON: Parse pregap for tracks in cue sheet 2023-10-12 23:54:48 +02:00
Eugene Sandulenko
4bd9e71f59 COMMON: Parse track performer in cue sheets 2023-10-12 23:54:48 +02:00
Eugene Sandulenko
41d7ca4c19 COMMON: Skip comments in CueSheets 2023-10-12 23:54:48 +02:00
Eugene Sandulenko
fef7a4b72d COMMON: Added track parsing to the CueSheet 2023-10-12 23:54:48 +02:00
Eugene Sandulenko
7c2514fe1d COMMON: Added parsing of cue sheet metadata to the CueSheet 2023-10-12 23:54:48 +02:00
Eugene Sandulenko
9f3b4b6128 COMMON: Parsing FILE token in CueSheets 2023-10-12 23:54:48 +02:00
Eugene Sandulenko
5284c8d7a0 COMMON: Addeed initial stub for CueSheet class 2023-10-12 23:54:48 +02:00
elasota
2f19102f44 COMMON: Avoid calling punycode_decodefilename on strings that aren't punycode. 2023-09-20 02:16:25 +02:00
elasota
e5e9d5c96d COMMON: Performance improvement for toUppercase and toLowercase: Avoid calling makeUnique on strings that aren't modified. 2023-09-20 02:16:25 +02:00
Eugene Sandulenko
7f4c0c9391
JANITORIAL: Remove trailing whitepaces 2023-09-19 15:16:20 +02:00
Eugene Sandulenko
6632467df7
COMMON: Add missing override keywords 2023-09-17 21:12:34 +02:00
elasota
63b01f5e85 COMMON: Strip trailing slashes from ZipArchive directories and improve directory detection. Add support for listChildren and isDirectory. 2023-09-17 19:17:33 +02:00
elasota
b93d803f3e COMMON: Add isDirectory and listChildren to FSNode and FSDirectoryFile 2023-09-17 19:17:33 +02:00
elasota
1155eb7894 COMMON: Add isPathDirectory to Archive, and isDirectory and listChildren to ArchiveMember 2023-09-17 19:17:33 +02:00