<feed xmlns='http://www.w3.org/2005/Atom'>
<title>squashfs-tools-ng.git/include, branch fixes-1.1.0</title>
<subtitle>A new set of tools and libraries for working with SquashFS images</subtitle>
<id>https://git.infraroot.at/squashfs-tools-ng.git/atom?h=fixes-1.1.0</id>
<link rel='self' href='https://git.infraroot.at/squashfs-tools-ng.git/atom?h=fixes-1.1.0'/>
<link rel='alternate' type='text/html' href='https://git.infraroot.at/squashfs-tools-ng.git/'/>
<updated>2022-08-19T16:47:52+00:00</updated>
<entry>
<title>Fix: libfstree: actually use a full 32 bit hard link counter</title>
<updated>2022-08-19T16:47:52+00:00</updated>
<author>
<name>David Oberhollenzer</name>
<email>david.oberhollenzer@sigma-star.at</email>
</author>
<published>2022-07-08T15:08:34+00:00</published>
<link rel='alternate' type='text/html' href='https://git.infraroot.at/squashfs-tools-ng.git/commit/?id=ce3a783daaa9b8f50d71cb3ac108e39002358a1e'/>
<id>urn:sha1:ce3a783daaa9b8f50d71cb3ac108e39002358a1e</id>
<content type='text'>
The squashfs on-disk format uses 32 bit link counters, but the fstree
used 16 bit ones. Because the link count also includes child nodes,
this artificially limited the number of entries in a directory to ~64k
files.

This patch removes the limit by switching libfstree to 32 bit counters.

Reported-by: Marvin Renich &lt;mrvn@renich.org&gt;
Signed-off-by: David Oberhollenzer &lt;david.oberhollenzer@sigma-star.at&gt;
</content>
</entry>
<entry>
<title>Windows: redirect standard I/O and convert text to UTF-16</title>
<updated>2022-03-10T20:53:29+00:00</updated>
<author>
<name>David Oberhollenzer</name>
<email>david.oberhollenzer@sigma-star.at</email>
</author>
<published>2022-03-10T20:22:36+00:00</published>
<link rel='alternate' type='text/html' href='https://git.infraroot.at/squashfs-tools-ng.git/commit/?id=6447b191eef8bf8f4942569e55c9a0f297c67a8e'/>
<id>urn:sha1:6447b191eef8bf8f4942569e55c9a0f297c67a8e</id>
<content type='text'>
Preprocessor magic is used to redirect putc/fputc/fputs/printf/fprintf
to custom implementations.

The custom implementations try to figure out if we are printing to the
console and, if so, convert the resulting strings to UTF-16 and print
them through ConsoleWriteW. If the output is redirected to a file or
a pipe, the original (presummed) UTF-8 is kept.

Simply setting the console output codepage to UTF-8 does not work,
because the standard I/O facilities of MSVCRT either does not support
unicode (in non-wchar mode), or has half-broken support through fputs,
which can still break up multi-byte sequences through its internal
buffering.

Likewise, changing the codepage and using ConsoleWriteA, or trying to
use fputws did not work in a test VM either.

This approach is the one that worked most consistently among the
ones tried, but also has problems. E.g. it breaks when setting the
codepage to UTF-8 manually (using `chcp 65001`).

Signed-off-by: David Oberhollenzer &lt;david.oberhollenzer@sigma-star.at&gt;
</content>
</entry>
<entry>
<title>Fix: consistently use the widechar file API on Windows</title>
<updated>2021-12-05T09:29:36+00:00</updated>
<author>
<name>David Oberhollenzer</name>
<email>david.oberhollenzer@sigma-star.at</email>
</author>
<published>2021-11-27T23:05:24+00:00</published>
<link rel='alternate' type='text/html' href='https://git.infraroot.at/squashfs-tools-ng.git/commit/?id=2b8eb19a4de81db470f7ff5021a8a4822cc8c80d'/>
<id>urn:sha1:2b8eb19a4de81db470f7ff5021a8a4822cc8c80d</id>
<content type='text'>
When opening files on windows, use the widechar versions and convert
from (assumed) UTF-8 to UTF-16 as needed.

Since the broken, code-page-random API may acutall be intended in some
use cases, leave that option in through an additional flag.

Signed-off-by: David Oberhollenzer &lt;david.oberhollenzer@sigma-star.at&gt;
</content>
</entry>
<entry>
<title>Add a wrapper for the main function on Windows</title>
<updated>2021-12-05T09:29:32+00:00</updated>
<author>
<name>David Oberhollenzer</name>
<email>david.oberhollenzer@sigma-star.at</email>
</author>
<published>2021-11-26T12:53:43+00:00</published>
<link rel='alternate' type='text/html' href='https://git.infraroot.at/squashfs-tools-ng.git/commit/?id=4a4dbe027a082e546512b5ccb2999753651a9a28'/>
<id>urn:sha1:4a4dbe027a082e546512b5ccb2999753651a9a28</id>
<content type='text'>
A macro and forward declaration are added to compat.h that rename
the main() function programs using compat.h into sqfs_tools_main.

An actual main() function is added to libcompat.a, that uses the
shell API to get the UTF-16 command line arguments, convert them
to UTF-8 and call sqfs_tools_main.

Signed-off-by: David Oberhollenzer &lt;david.oberhollenzer@sigma-star.at&gt;
</content>
</entry>
<entry>
<title>Fix libsquashfs directory writer size accounting</title>
<updated>2021-07-21T07:56:31+00:00</updated>
<author>
<name>David Oberhollenzer</name>
<email>david.oberhollenzer@sigma-star.at</email>
</author>
<published>2021-07-21T07:41:47+00:00</published>
<link rel='alternate' type='text/html' href='https://git.infraroot.at/squashfs-tools-ng.git/commit/?id=248494992442fbde7eb6ca3979a778d82fa86016'/>
<id>urn:sha1:248494992442fbde7eb6ca3979a778d82fa86016</id>
<content type='text'>
The squashfs readdir() implementation in the Linux kernel returns
non-existing "." and ".." entries for offsets 0 and 1, and after
that reads from disk. For convenience, it was decided to store an
off-by-3 value on disk instead of doing complex primary school math
to adjust for this. This didn't show up until now, because the kernel
implementation trusts the value from the directory header more than
the actual size in the inode and happily reads 3 more than the inode
would allow it to. This only showed up with 7-zip which subtracts 3
from the size and expects the result to be exact and bails if the
directory headers suggest otherwise.

And yes, I did consider making a "Holy Hand Granade of Antioch"
reference, but consciously decided not to.

Signed-off-by: David Oberhollenzer &lt;david.oberhollenzer@sigma-star.at&gt;
</content>
</entry>
<entry>
<title>Remove casual un-const casting in various places</title>
<updated>2021-06-25T13:12:41+00:00</updated>
<author>
<name>David Oberhollenzer</name>
<email>david.oberhollenzer@sigma-star.at</email>
</author>
<published>2021-06-24T14:07:45+00:00</published>
<link rel='alternate' type='text/html' href='https://git.infraroot.at/squashfs-tools-ng.git/commit/?id=8348086b48af0cbabe4cf2b64992ced6561ea50c'/>
<id>urn:sha1:8348086b48af0cbabe4cf2b64992ced6561ea50c</id>
<content type='text'>
Signed-off-by: David Oberhollenzer &lt;david.oberhollenzer@sigma-star.at&gt;
</content>
</entry>
<entry>
<title>libfstream: Add printf format specifier attribute</title>
<updated>2021-06-25T12:36:11+00:00</updated>
<author>
<name>David Oberhollenzer</name>
<email>david.oberhollenzer@sigma-star.at</email>
</author>
<published>2021-06-24T12:30:40+00:00</published>
<link rel='alternate' type='text/html' href='https://git.infraroot.at/squashfs-tools-ng.git/commit/?id=e0cab1937a05d5c9740adf10613aa183eee7d99c'/>
<id>urn:sha1:e0cab1937a05d5c9740adf10613aa183eee7d99c</id>
<content type='text'>
Signed-off-by: David Oberhollenzer &lt;david.oberhollenzer@sigma-star.at&gt;
</content>
</entry>
<entry>
<title>Use *_MAX to remove need for configure-time type size checks</title>
<updated>2021-05-16T15:25:02+00:00</updated>
<author>
<name>Michael Forney</name>
<email>mforney@mforney.org</email>
</author>
<published>2020-05-30T08:23:59+00:00</published>
<link rel='alternate' type='text/html' href='https://git.infraroot.at/squashfs-tools-ng.git/commit/?id=91d628c5cf067432bc78b728a0bf4f56aee3e407'/>
<id>urn:sha1:91d628c5cf067432bc78b728a0bf4f56aee3e407</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Fix: libsquashfs: allow static linking on Windows</title>
<updated>2021-04-09T09:55:04+00:00</updated>
<author>
<name>David Oberhollenzer</name>
<email>david.oberhollenzer@sigma-star.at</email>
</author>
<published>2021-04-08T10:18:17+00:00</published>
<link rel='alternate' type='text/html' href='https://git.infraroot.at/squashfs-tools-ng.git/commit/?id=f92d3354df3c0bb930b103a58d905a77a7281a26'/>
<id>urn:sha1:f92d3354df3c0bb930b103a58d905a77a7281a26</id>
<content type='text'>
If SQFS_STATIC is defined, dummy out the SQFS_API definition, so we
don't try to pull stuff from a (in this case) non-existant DLL or
try to export functions.

Signed-off-by: David Oberhollenzer &lt;david.oberhollenzer@sigma-star.at&gt;
</content>
</entry>
<entry>
<title>Fix: libsquashfs: visibillity of mempool functions</title>
<updated>2021-04-08T10:06:03+00:00</updated>
<author>
<name>David Oberhollenzer</name>
<email>david.oberhollenzer@sigma-star.at</email>
</author>
<published>2021-04-08T10:06:03+00:00</published>
<link rel='alternate' type='text/html' href='https://git.infraroot.at/squashfs-tools-ng.git/commit/?id=65955d6c48319124c12c7901fb0c0cf8a466a1a1'/>
<id>urn:sha1:65955d6c48319124c12c7901fb0c0cf8a466a1a1</id>
<content type='text'>
Signed-off-by: David Oberhollenzer &lt;david.oberhollenzer@sigma-star.at&gt;
</content>
</entry>
</feed>
