Skip to contentSkip to conversation

libtracefs: Fix code indentation

PATCH New Yordan Karadzhov (VMware) 1 participant 1 message Sep 24, 2021

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 libtracefs: Fix code indentation

This is a code style fix. No functional changes are introduced.

---

I am re-sending this patch because the Tzvetomir reported problems applying the previous version.

 include/tracefs.h  |  3 +--
 src/tracefs-hist.c | 12 ++++++------
 2 files changed, 7 insertions(+), 8 deletions(-)
include/tracefs.h +1 -2
index 25abbdc..9d84777 100644
@@ -309,8 +309,7 @@ enum tracefs_compare {
 	TRACEFS_COMPARE_AND,
 };
 
-void tracefs_hist_free
-(struct tracefs_hist *hist);
+void tracefs_hist_free(struct tracefs_hist *hist);
 struct tracefs_hist *
 tracefs_hist_alloc(struct tep_handle *tep,
 		   const char *system, const char *event,
src/tracefs-hist.c +6 -6
index 003715f..eeb8374 100644
@@ -206,8 +206,8 @@ void tracefs_hist_free(struct tracefs_hist *hist)
  */
 struct tracefs_hist *
 tracefs_hist_alloc(struct tep_handle *tep,
-			const char *system, const char *event_name,
-			const char *key, enum tracefs_hist_key_type type)
+		   const char *system, const char *event_name,
+		   const char *key, enum tracefs_hist_key_type type)
 {
 	struct tep_event *event;
 	struct tracefs_hist *hist;
@@ -366,10 +366,10 @@ add_sort_key(struct tracefs_hist *hist, const char *sort_key, char **list)
 
 	if (!key_list[i]) {
 		for (i = 0; val_list[i]; i++) {
-		if (strcmp(val_list[i], sort_key) == 0)
-			break;
-		if (!val_list[i])
-			return NULL;
+			if (strcmp(val_list[i], sort_key) == 0)
+				break;
+			if (!val_list[i])
+				return NULL;
 		}
 	}
 
Signature · 1 line
2.30.2