summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Habets <thomas@habets.se>2019-10-24 13:35:13 +0100
committerGitHub <noreply@github.com>2019-10-24 13:35:13 +0100
commit92c9786127df61d49cbbff7b5d2b231414e373ef (patch)
treeb5d15fcabbade93ae2e2a46379e1f382d46f4d41
parent8b0b4c06943567c675d9569d4b43ed1f7daff2fe (diff)
downloadarping-92c9786127df61d49cbbff7b5d2b231414e373ef.tar.gz
Add notes on coding style
-rw-r--r--HACKING.md12
1 files changed, 12 insertions, 0 deletions
diff --git a/HACKING.md b/HACKING.md
index 055b8dc..14d49e6 100644
--- a/HACKING.md
+++ b/HACKING.md
@@ -1,5 +1,17 @@
# Hacking on Arping
+## Coding style
+
+* C99 to retain portability for the widest range of platforms
+* Approximately [Linux kernel coding style][1], except:
+ * Line break before function name, in function definitions.
+ * Curly braces are mandatory.
+ * Place `*` next to the type, not the name. E.g. `char* p`
+
+Don't make style-only changes, but fix the style on the line you're touching anyway.
+
+[1]: https://github.com/torvalds/linux/blob/master/Documentation/process/coding-style.rst
+
## Make release
1. Up version in configure.ac. Commit.
2. Run `./extra/mktarball HEAD`