From 73eee8e54247e339a540ea31d803282e0aa91c99 Mon Sep 17 00:00:00 2001
From: Henry Weller <http://cfd.direct>
Date: Wed, 24 Aug 2016 11:24:27 +0100
Subject: [PATCH] functionObjects::forces: Corrected file names when using the
 'binData' option Resolves bug-report
 http://bugs.openfoam.org/view.php?id=2214

---
 src/functionObjects/forces/forces/forces.C | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/src/functionObjects/forces/forces/forces.C b/src/functionObjects/forces/forces/forces.C
index b8e0f133db..f2d13dba60 100644
--- a/src/functionObjects/forces/forces/forces.C
+++ b/src/functionObjects/forces/forces/forces.C
@@ -53,6 +53,7 @@ Foam::wordList Foam::functionObjects::forces::createFileNames
     DynamicList<word> names(1);
 
     const word forceType(dict.lookup("type"));
+    names.append(forceType);
 
     if (dict.found("binData"))
     {
@@ -64,8 +65,6 @@ Foam::wordList Foam::functionObjects::forces::createFileNames
         }
     }
 
-    names.append(forceType);
-
     return names;
 }
 
-- 
GitLab