Commit Graph

36 Commits

Author SHA1 Message Date
Max Kellermann
cfd26f53f0 fs/io/FileOutputStream: fix wrong #ifdef WIN32 2015-03-25 17:28:27 +01:00
Max Kellermann
7f3518333d Mapper: don't use C-style prototypes 2015-03-24 22:03:17 +01:00
Max Kellermann
f1f871f103 fs/io/FileOutputStream: add method Tell() 2015-03-24 22:00:10 +01:00
Max Kellermann
6387b52896 fs/io/FileOutputStream: seek end-of-file in AppendFileOutputStream ctor 2015-03-24 21:59:34 +01:00
Max Kellermann
7f6e1fbc8d fs/io/FileOutputStream: add class AppendFileOutputStream 2015-03-23 22:51:33 +01:00
Max Kellermann
06827cfcf1 fs/io/FileOutputStream: move code to new class BaseFileOutputStream 2015-03-23 22:36:03 +01:00
Max Kellermann
6dc3097998 fs/io/FileOutputStream: make "path" const 2015-03-23 22:35:56 +01:00
Max Kellermann
cd35271698 fs/io/BufferedOutputStream: add code comments 2015-03-23 22:03:25 +01:00
Max Kellermann
b31d171ae8 *: doxygen fixups 2015-03-17 11:21:43 +01:00
Max Kellermann
cd08e5c7da fs/io/FileOutputStream: use class FileDescriptor 2015-03-03 23:04:25 +01:00
Max Kellermann
57ad3aca8e input/file: use class FileReader 2015-03-03 21:48:45 +01:00
Max Kellermann
a5760670ef fs/io/FileReader: add method GetFileInfo() 2015-03-03 21:41:11 +01:00
Max Kellermann
f04a3ec201 fs/io/FileReader: add move constructor 2015-03-03 21:41:10 +01:00
Max Kellermann
40a587bbaf system/FileDescriptor: new wrapper class for a file descriptor 2015-03-03 17:14:30 +01:00
Max Kellermann
dd5daa0767 fs/io/FileReader: add method Seek() 2015-03-03 14:29:36 +01:00
Max Kellermann
00b0f6ad51 fs/io/File{Reader,OutputStream}: convert path to UTF-8 for error message 2015-02-25 19:10:51 +01:00
Max Kellermann
9c83d3c78c fs/io/FileOutputStream: use CREATE_ALWAYS instead of TRUNCATE_EXISTING
Fixes yet another breakage of creating the database+state file on
Windows.
2015-02-10 13:41:09 +01:00
Max Kellermann
ff2b427cc1 release v0.19.9
-----BEGIN PGP SIGNATURE-----
 Version: GnuPG v2
 
 iQIcBAABCAAGBQJU1OdDAAoJECNuiljG20USazsQAKZuhjJJ8vjYCB7G/NGoi9tv
 dImBQnQDiQTdE57kxa46loknbPc5/cSAYnLbR4PjQfMBqArtE6sAkAk72LKlYNqt
 qMOEKPCBjv8ZjiGDbvL/X+WSKbrpm8iOf3Gu5BRIuWrMK/oXQMe5A028Ziyye//X
 XfMKdPWkZFL6h/qGO082eCnCiTJaSRLwP6HSNF2pqv+JuFF7hyLkZvTVXo/ms85E
 ezrx3Kjf8TuNX041uuso7qqUsD/sY2jZRZ26qfzJ1ODwJmgIfbXzat+ODFVNne55
 E1nh5zpwIUxZ2+d6eJEzwLR3+FpmltPc1YLo2mnetD6f59SzpXjAycPLo1VoOhbQ
 s4iXQEzNI2LwDebI3eiMXQaLIorHOGex3L6JYkO5LAqUkPrv/PBCJFJs8ixjCRbl
 KL27WmWYiV0xfdCz4TtAxEt48LGMMjDfaSK4Hzo3vN3vZtIEy2p/pS9MhXDdxC8I
 vql533N+A9fi2I+7bPauwX5ElOYvGTkDeKqKXDox/jR0zio55APst7IW9OIUCKxo
 an98430jeNPhs1CNqxVIJNciC8Q4REmafki7UQiKYDBQjHyq3r6Bp547lnDhUtii
 P9PNTyOoJXhV5yEP3upnWCxwH6Vy7IxBnwrEO7aEHs88Ea54iqlZ9XB8TzUw4G/1
 I7T7a8yOopRopb04vhr2
 =fd8f
 -----END PGP SIGNATURE-----

Merge tag 'v0.19.9'
2015-02-06 17:15:31 +01:00
Max Kellermann
d38034bb5c fs/io/FileOutputStream: don't auto-delete file on WIN32
The file handle is never reset to INVALID_HANDLE_VALUE, and thus the
destructor will assume the operation shall be cancelled and will
delete the temporary file.

This was a major breakage for saving the database file and the state
file.
2015-02-06 14:36:55 +01:00
Max Kellermann
6cdb2a4896 fs/io/BufferedReader: count line numbers
Replaces the dirty code in config/ConfigFile.cxx.
2015-01-21 23:43:32 +01:00
Max Kellermann
eaf0662b75 fs/io/FileOutputStream: add static method Create() 2015-01-14 19:44:28 +01:00
Max Kellermann
8b217d5313 fs/io/FileOutputStream: use O_TMPFILE if available
The Linux feature allows writing new files to an invisible file, and
then replace the old file.  This preserves the old file if we get
interrupted by some event.
2015-01-06 19:38:55 +01:00
Max Kellermann
81df45a893 fs/io/File{Reader,OutputStream}: use OpenFile() 2015-01-05 23:13:35 +01:00
Max Kellermann
712ed555e6 Copyright year 2015 2015-01-01 19:48:13 +01:00
Max Kellermann
b3f5b4932c configure.ac: add macro MPD_ENABLE_AUTO_PKG
Simplify the definition of many build options.
2014-11-21 22:19:57 +01:00
Max Kellermann
b373c53ce4 *: add missing Compiler.h includes
Necessary for "final" on gcc 4.6.
2014-08-30 00:46:52 +02:00
Max Kellermann
8283f23651 fs/io/TextFile: add method Check() 2014-08-11 22:53:48 +02:00
Max Kellermann
7cc25f91ff fs/io/Reader: add "nonnull" attribute 2014-08-11 22:49:08 +02:00
Max Kellermann
486b5b6bfc fs/io/TextFile: use AutoGunzipReader
Several MPD subsystems can now read gzipped files; for example, the
database file can be gzipped.
2014-08-11 21:48:25 +02:00
Max Kellermann
88a2f128ec fs/io/AutoGunzipReader: new class 2014-08-11 21:48:25 +02:00
Max Kellermann
45c139cfb3 fs/io/PeekReader: new utility class 2014-08-11 21:48:25 +02:00
Max Kellermann
3a111e5d74 fs/io/GzipOutputStream,GunzipReader: move zlib_domain to src/lib/zlib/Domain.cxx 2014-08-11 21:48:25 +02:00
Max Kellermann
a67a881715 input/GunzipInputStream: new class 2014-08-08 20:11:29 +02:00
Max Kellermann
aa2e4d92e0 fs/io/BufferedReader: new class to replace class TextFile
The new class is pluggable, to prepare for gzipped database files.

For now, the TextFile class remains, and will be refactored away
later.
2014-08-07 19:38:25 +02:00
Max Kellermann
0ea66a1275 fs/io/Reader: new interface 2014-08-07 19:38:25 +02:00
Max Kellermann
aafff8fd5c fs/output, fs/TextFile: move to fs/io/ 2014-08-07 19:38:25 +02:00