#include "file.h"
+BT_HIDDEN
void ctf_fs_file_destroy(struct ctf_fs_file *file)
{
struct ctf_fs_component *ctf_fs = file->ctf_fs;
g_free(file);
}
+BT_HIDDEN
struct ctf_fs_file *ctf_fs_file_create(struct ctf_fs_component *ctf_fs)
{
struct ctf_fs_file *file = g_new0(struct ctf_fs_file, 1);
return file;
}
+BT_HIDDEN
int ctf_fs_file_open(struct ctf_fs_component *ctf_fs, struct ctf_fs_file *file,
const char *mode)
{
PDBG("Opening file \"%s\" with mode \"%s\"\n", file->path->str, mode);
file->fp = fopen(file->path->str, mode);
if (!file->fp) {
- PERR("Cannot open file \"%s\" with mode \"%s\": %s",
+ PERR("Cannot open file \"%s\" with mode \"%s\": %s\n",
file->path->str, mode, strerror(errno));
goto error;
}