aboutsummaryrefslogtreecommitdiffstats
path: root/src/fs/TextFile.hxx
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2014-02-17 23:04:06 +0100
committerMax Kellermann <max@duempel.org>2014-02-17 23:04:10 +0100
commit1709ab6810486648ac23bcf683d4e2326ede9d5a (patch)
tree468d7c44ce60dde98683c32297fe036fa765b166 /src/fs/TextFile.hxx
parentce925ba56fdcdf6168db7597185f6c34643a7501 (diff)
downloadmpd-1709ab6810486648ac23bcf683d4e2326ede9d5a.tar.gz
mpd-1709ab6810486648ac23bcf683d4e2326ede9d5a.tar.xz
mpd-1709ab6810486648ac23bcf683d4e2326ede9d5a.zip
fs/TextFile: use custom allocation instead of GString
Diffstat (limited to 'src/fs/TextFile.hxx')
-rw-r--r--src/fs/TextFile.hxx5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/fs/TextFile.hxx b/src/fs/TextFile.hxx
index b4b850c0f..e3a712a88 100644
--- a/src/fs/TextFile.hxx
+++ b/src/fs/TextFile.hxx
@@ -23,9 +23,9 @@
#include "Compiler.h"
#include <stdio.h>
+#include <stddef.h>
class Path;
-typedef struct _GString GString;
class TextFile {
static constexpr size_t max_length = 512 * 1024;
@@ -33,7 +33,8 @@ class TextFile {
FILE *const file;
- GString *const buffer;
+ char *buffer;
+ size_t capacity, length;
public:
TextFile(Path path_fs);