summaryrefslogtreecommitdiff
path: root/cpufreq
diff options
context:
space:
mode:
Diffstat (limited to 'cpufreq')
-rw-r--r--cpufreq/src/cpufreq-utils.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/cpufreq/src/cpufreq-utils.c b/cpufreq/src/cpufreq-utils.c
index 7afe0db6..3e3325ca 100644
--- a/cpufreq/src/cpufreq-utils.c
+++ b/cpufreq/src/cpufreq-utils.c
@@ -299,11 +299,12 @@ cpufreq_file_get_contents (const gchar *filename,
g_free (display_filename);
- if (buffer)
+ if (buffer) {
*contents = g_string_free (buffer, FALSE);
-
- if (length)
- *length = strlen (*contents);
+
+ if (length)
+ *length = strlen (*contents);
+ }
close (fd);