-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
35 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
# Contribution Guidelines | ||
|
||
# Main Rules | ||
|
||
* All code must have unit tests written with `cmocka` | ||
* All code must pass valgrind testing with `ctest -T memcheck` | ||
* All code must be formatted with `make format` | ||
* All newly written typedefs, global variables, function declarations, etc.. must having valid doxygen comments | ||
|
||
# Memory Allocations | ||
|
||
* Where possible conduct memory allocations outside of mutex locks | ||
* This helps minimize the time spend in a lock, thus minimizing the time we block other threads | ||
|
||
# Braces | ||
|
||
|
||
You must always have the opening brace on the same line of the expression. | ||
|
||
For example the following is acceptable | ||
|
||
```C | ||
if (abc == true) { | ||
/* do stuff */ | ||
} | ||
``` | ||
|
||
Whereas the following is not acceptable: | ||
|
||
```C | ||
if (abc == true) | ||
{ | ||
/* do stuff */ | ||
} | ||
``` |