Skip to content

Commit

Permalink
Merge pull request #1819 from ibpsa/issue1818_headerFiles
Browse files Browse the repository at this point in the history
Added header files and ifdef statements
  • Loading branch information
LauraMaier authored Dec 5, 2023
2 parents 5250513 + 48b14a8 commit 3fad3f6
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 0 deletions.
6 changes: 6 additions & 0 deletions IBPSA/Resources/C-Sources/fileWriterFree.c
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@
*
* Michael Wetter, LBNL 2018-05-12
*/

#ifndef IBPSA_FILEWRITERFree_c
#define IBPSA_FILEWRITERFree_c

#include <stdlib.h>
#include <stdio.h>
#include "ModelicaUtilities.h"
Expand Down Expand Up @@ -62,3 +66,5 @@ void fileWriterFree(void* ptrFileWriter){

return;
}

#endif
3 changes: 3 additions & 0 deletions IBPSA/Resources/C-Sources/fileWriterStructure.c
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
#ifndef IBPSA_FILEWRITERStructure_c
#define IBPSA_FILEWRITERStructure_c

#include <stdlib.h>
#include <string.h>

#include "ModelicaUtilities.h"

#include "fileWriterStructure.h"
Expand Down
8 changes: 8 additions & 0 deletions IBPSA/Resources/C-Sources/jsonWriterInit.c
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,12 @@
* Filip Jorissen, KU Leuven
*/

#ifndef IBPSA_JSONWRITERINIT_c
#define IBPSA_JSONWRITERINIT_c

#include <stdlib.h>
#include <string.h>

#include "fileWriterStructure.c"
#include "ModelicaUtilities.h"

Expand Down Expand Up @@ -90,3 +96,5 @@ void writeJson(void *ptrFileWriter, const double* varVals, const int numVals){
if (fclose(fOut) == EOF)
ModelicaFormatError("In writeJson.c: Returned an error when closing %s.", ID->fileWriterName);
}

#endif

0 comments on commit 3fad3f6

Please sign in to comment.