summaryrefslogtreecommitdiffstats
path: root/firmware/target/hosted/ibasso/sysfs-ibasso.c
diff options
context:
space:
mode:
Diffstat (limited to 'firmware/target/hosted/ibasso/sysfs-ibasso.c')
-rw-r--r--firmware/target/hosted/ibasso/sysfs-ibasso.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/firmware/target/hosted/ibasso/sysfs-ibasso.c b/firmware/target/hosted/ibasso/sysfs-ibasso.c
index 5269c16704..8f62e3fec2 100644
--- a/firmware/target/hosted/ibasso/sysfs-ibasso.c
+++ b/firmware/target/hosted/ibasso/sysfs-ibasso.c
@@ -122,7 +122,7 @@ static const char* SYSFS_PATHS[] =
static FILE* open_read(const char* file_name)
{
- FILE *f = fopen(file_name, "r");
+ FILE *f = fopen(file_name, "re");
if(f == NULL)
{
DEBUGF("ERROR %s: Can not open %s for reading.", __func__, file_name);
@@ -134,7 +134,7 @@ static FILE* open_read(const char* file_name)
static FILE* open_write(const char* file_name)
{
- FILE *f = fopen(file_name, "w");
+ FILE *f = fopen(file_name, "we");
if(f == NULL)
{
DEBUGF("ERROR %s: Can not open %s for writing.", __func__, file_name);