Browse code

core, lib, modules: restructured source code tree

- new folder src/ to hold the source code for main project applications
- main.c is in src/
- all core files are subfolder are in src/core/
- modules are in src/modules/
- libs are in src/lib/
- application Makefiles are in src/
- application binary is built in src/ (src/kamailio)

Daniel-Constantin Mierla authored on 07/12/2016 11:03:51
Showing 1 changed files
1 1
deleted file mode 100644
... ...
@@ -1,50 +0,0 @@
1
-/*
2
- * Copyright (C) 2007 iptelorg GmbH 
3
- *
4
- * Permission to use, copy, modify, and distribute this software for any
5
- * purpose with or without fee is hereby granted, provided that the above
6
- * copyright notice and this permission notice appear in all copies.
7
- *
8
- * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
9
- * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
10
- * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
11
- * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
12
- * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
13
- * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
14
- * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
15
- */
16
-
17
-/**
18
- * @file
19
- * @brief Kamailio TLS support :: TLS hooks init
20
- * @ingroup tls
21
- * Module: @ref tls
22
- */
23
-
24
-
25
-#ifndef _tls_hooks_init_h
26
-#define _tls_hooks_init_h
27
-
28
-#ifdef TLS_HOOKS
29
-
30
-#include "ip_addr.h" /* socket_info */
31
-
32
-#ifndef USE_TLS
33
-#error "USE_TLS required and not defined (please compile with make \
34
-	TLS_HOOKS=1)"
35
-#endif
36
-
37
-#ifdef CORE_TLS
38
-#error "Conflict: CORE_TLS and TLS_HOOKS cannot be defined in the same time"
39
-#endif
40
-
41
-
42
-int tls_loaded(void);
43
-int tls_has_init_si(void); /*returns true if a handle for tls_init is registered*/
44
-int tls_init(struct socket_info* si);
45
-int init_tls(void);
46
-void destroy_tls(void);
47
-int pre_init_tls(void);
48
-
49
-#endif /* TLS_HOOKS */
50
-#endif
Browse code

core: tls hooks can execute a callback before modules init function is executed

- useful to prepare tls environment before a module might access it
- executed after modparam but before mod_init

Daniel-Constantin Mierla authored on 25/01/2015 09:57:00
Showing 1 changed files
... ...
@@ -44,6 +44,7 @@ int tls_has_init_si(void); /*returns true if a handle for tls_init is registered
44 44
 int tls_init(struct socket_info* si);
45 45
 int init_tls(void);
46 46
 void destroy_tls(void);
47
+int pre_init_tls(void);
47 48
 
48 49
 #endif /* TLS_HOOKS */
49 50
 #endif
Browse code

core: Modify doxygen, remove history, remove SVN IDs, change "ser" and "sip-router" to "KAMAILIO"

Olle E. Johansson authored on 16/01/2015 16:38:46
Showing 1 changed files
... ...
@@ -1,6 +1,4 @@
1 1
 /*
2
- * $Id$
3
- *
4 2
  * Copyright (C) 2007 iptelorg GmbH 
5 3
  *
6 4
  * Permission to use, copy, modify, and distribute this software for any
... ...
@@ -15,17 +13,10 @@
15 13
  * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
16 14
  * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
17 15
  */
18
-/*
19
- * tls hooks init
20
- *
21
- * History:
22
- * --------
23
- *  2007-02-09  created by andrei
24
- */
25 16
 
26 17
 /**
27 18
  * @file
28
- * @brief SIP-router TLS support :: TLS hooks init
19
+ * @brief Kamailio TLS support :: TLS hooks init
29 20
  * @ingroup tls
30 21
  * Module: @ref tls
31 22
  */
Browse code

core: Added void to declarations of functions with empty argument list

In C language, a declaration in the form int f(); is equivalent to int f(...);, thus being able to accept an indefinit number of parameters. With the -Wstrict-prototypes GCC options, these declarations are reported as "function declaration isn’t a prototype".
On some cases, this may trick the compiler into generating unoptimized code (like preparing to handle variadic argument list).
In all cases having a declaration int f() and a definition inf f(int) is missleading, even if standard compliant.
This is still Work in Progress. (maybe adding the -Wstrict-prototypes option to default is desireable)

Marius Zbihlei authored on 02/04/2012 14:19:17
Showing 1 changed files
... ...
@@ -48,11 +48,11 @@
48 48
 #endif
49 49
 
50 50
 
51
-int tls_loaded();
52
-int tls_has_init_si(); /*returns true if a handle for tls_init is registered*/
51
+int tls_loaded(void);
52
+int tls_has_init_si(void); /*returns true if a handle for tls_init is registered*/
53 53
 int tls_init(struct socket_info* si);
54
-int init_tls();
55
-void destroy_tls();
54
+int init_tls(void);
55
+void destroy_tls(void);
56 56
 
57 57
 #endif /* TLS_HOOKS */
58 58
 #endif
Browse code

Doxygen updates

oej authored on 22/10/2009 17:59:29
Showing 1 changed files
... ...
@@ -23,6 +23,14 @@
23 23
  *  2007-02-09  created by andrei
24 24
  */
25 25
 
26
+/**
27
+ * @file
28
+ * @brief SIP-router TLS support :: TLS hooks init
29
+ * @ingroup tls
30
+ * Module: @ref tls
31
+ */
32
+
33
+
26 34
 #ifndef _tls_hooks_init_h
27 35
 #define _tls_hooks_init_h
28 36
 
Browse code

- tls hooks support: special tls hooks added in core that allow a module or core part to provide a tls implementation. Support for the old in-core tls compile options is preserved (but one can compile with either tls hooks support or tls-in-core support, not with both in the same time). Changes were kept to a minimum. - Makefiles: make TLS=1 deprecated, use instead make TLS_HOOKS=1 or make CORE_TLS=1 (if in-core tls support is needed). Added TLS_EXTRA_LIBS (e.g. make CORE_TLS=1 TLS_EXTRA_LIBS="-lz -lkrb5").

Andrei Pelinescu-Onciul authored on 10/02/2007 18:52:48
Showing 1 changed files
1 1
new file mode 100644
... ...
@@ -0,0 +1,50 @@
1
+/*
2
+ * $Id$
3
+ *
4
+ * Copyright (C) 2007 iptelorg GmbH 
5
+ *
6
+ * Permission to use, copy, modify, and distribute this software for any
7
+ * purpose with or without fee is hereby granted, provided that the above
8
+ * copyright notice and this permission notice appear in all copies.
9
+ *
10
+ * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
11
+ * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
12
+ * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
13
+ * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
14
+ * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
15
+ * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
16
+ * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
17
+ */
18
+/*
19
+ * tls hooks init
20
+ *
21
+ * History:
22
+ * --------
23
+ *  2007-02-09  created by andrei
24
+ */
25
+
26
+#ifndef _tls_hooks_init_h
27
+#define _tls_hooks_init_h
28
+
29
+#ifdef TLS_HOOKS
30
+
31
+#include "ip_addr.h" /* socket_info */
32
+
33
+#ifndef USE_TLS
34
+#error "USE_TLS required and not defined (please compile with make \
35
+	TLS_HOOKS=1)"
36
+#endif
37
+
38
+#ifdef CORE_TLS
39
+#error "Conflict: CORE_TLS and TLS_HOOKS cannot be defined in the same time"
40
+#endif
41
+
42
+
43
+int tls_loaded();
44
+int tls_has_init_si(); /*returns true if a handle for tls_init is registered*/
45
+int tls_init(struct socket_info* si);
46
+int init_tls();
47
+void destroy_tls();
48
+
49
+#endif /* TLS_HOOKS */
50
+#endif