projects
/
haproxy-3.0.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
a7b9baa
)
BUILD: import: guard plock.h against multiple inclusion
author
Willy Tarreau
<w@1wt.eu>
Sat, 26 Aug 2023 15:27:24 +0000
(17:27 +0200)
committer
Willy Tarreau
<w@1wt.eu>
Sat, 26 Aug 2023 15:28:08 +0000
(17:28 +0200)
Surprisingly there's no include guard in plock.h though there is one in
atomic-ops.h. Let's add one, or we cannot risk including the file multiple
times.
include/import/plock.h
patch
|
blob
|
history
diff --git
a/include/import/plock.h
b/include/import/plock.h
index
4fc258d
..
0ac7020
100644
(file)
--- a/
include/import/plock.h
+++ b/
include/import/plock.h
@@
-23,6
+23,9
@@
* OTHER DEALINGS IN THE SOFTWARE.
*/
+#ifndef PL_PLOCK_H
+#define PL_PLOCK_H
+
#include "atomic-ops.h"
#ifdef _POSIX_PRIORITY_SCHEDULING
#include <sched.h>
@@
-1415,3
+1418,5
@@
static inline void pl_lorw_unlock(unsigned long *lock)
else
pl_lorw_rdunlock(lock);
}
+
+#endif /* PL_PLOCK_H */