* fix another bunch of gcc 4.5 'no real prototype' warnings by making the MD5
functions typesafe (removing this PROTO_LIST stuff)
* refactoring of function definitions to use a proper style, like everybody else
* remove not needed defines for datatypes, delete the then empty header completely
* remove the unneeded include of md5global.h from a few modules
* fix callers of MD5 utility functions which already use a proper type
* adapt format of RSA copyright notices to the common style as well
* add doxygen documentations to all functions and defines
* similar changes have been done in kamailio, but have been not ported to this
repository yet
1 | 1 |
deleted file mode 100644 |
... | ... |
@@ -1,38 +0,0 @@ |
1 |
-/* GLOBAL.H - RSAREF types and constants |
|
2 |
- * |
|
3 |
- */ |
|
4 |
- |
|
5 |
- |
|
6 |
-/* PROTOTYPES should be set to one if and only if the compiler supports |
|
7 |
- function argument prototyping. |
|
8 |
-The following makes PROTOTYPES default to 0 if it has not already |
|
9 |
- been defined with C compiler flags. |
|
10 |
- */ |
|
11 |
-#ifndef MD5GLOBAL_H |
|
12 |
-#define MD5GLOBAL_H |
|
13 |
- |
|
14 |
- |
|
15 |
-#ifndef PROTOTYPES |
|
16 |
-#define PROTOTYPES 0 |
|
17 |
-#endif |
|
18 |
- |
|
19 |
-/* POINTER defines a generic pointer type */ |
|
20 |
-typedef unsigned char *POINTER; |
|
21 |
- |
|
22 |
-/* UINT2 defines a two byte word */ |
|
23 |
-typedef unsigned short int UINT2; |
|
24 |
- |
|
25 |
-/* UINT4 defines a four byte word */ |
|
26 |
-typedef unsigned int UINT4; |
|
27 |
- |
|
28 |
-/* PROTO_LIST is defined depending on how PROTOTYPES is defined above. |
|
29 |
-If using PROTOTYPES, then PROTO_LIST returns the list, otherwise it |
|
30 |
- returns an empty list. |
|
31 |
- */ |
|
32 |
-#if PROTOTYPES |
|
33 |
-#define PROTO_LIST(list) list |
|
34 |
-#else |
|
35 |
-#define PROTO_LIST(list) () |
|
36 |
-#endif |
|
37 |
- |
|
38 |
-#endif /* MD5GLOBAL_H */ |
... | ... |
@@ -23,7 +23,7 @@ typedef unsigned char *POINTER; |
23 | 23 |
typedef unsigned short int UINT2; |
24 | 24 |
|
25 | 25 |
/* UINT4 defines a four byte word */ |
26 |
-typedef unsigned long int UINT4; |
|
26 |
+typedef unsigned int UINT4; |
|
27 | 27 |
|
28 | 28 |
/* PROTO_LIST is defined depending on how PROTOTYPES is defined above. |
29 | 29 |
If using PROTOTYPES, then PROTO_LIST returns the list, otherwise it |
... | ... |
@@ -8,6 +8,10 @@ |
8 | 8 |
The following makes PROTOTYPES default to 0 if it has not already |
9 | 9 |
been defined with C compiler flags. |
10 | 10 |
*/ |
11 |
+#ifndef MD5GLOBAL_H |
|
12 |
+#define MD5GLOBAL_H |
|
13 |
+ |
|
14 |
+ |
|
11 | 15 |
#ifndef PROTOTYPES |
12 | 16 |
#define PROTOTYPES 0 |
13 | 17 |
#endif |
... | ... |
@@ -31,3 +35,4 @@ If using PROTOTYPES, then PROTO_LIST returns the list, otherwise it |
31 | 35 |
#define PROTO_LIST(list) () |
32 | 36 |
#endif |
33 | 37 |
|
38 |
+#endif /* MD5GLOBAL_H */ |
1 | 1 |
new file mode 100644 |
... | ... |
@@ -0,0 +1,31 @@ |
1 |
+/* GLOBAL.H - RSAREF types and constants |
|
2 |
+ */ |
|
3 |
+ |
|
4 |
+/* PROTOTYPES should be set to one if and only if the compiler supports |
|
5 |
+ function argument prototyping. |
|
6 |
+The following makes PROTOTYPES default to 0 if it has not already |
|
7 |
+ been defined with C compiler flags. |
|
8 |
+ */ |
|
9 |
+#ifndef PROTOTYPES |
|
10 |
+#define PROTOTYPES 0 |
|
11 |
+#endif |
|
12 |
+ |
|
13 |
+/* POINTER defines a generic pointer type */ |
|
14 |
+typedef unsigned char *POINTER; |
|
15 |
+ |
|
16 |
+/* UINT2 defines a two byte word */ |
|
17 |
+typedef unsigned short int UINT2; |
|
18 |
+ |
|
19 |
+/* UINT4 defines a four byte word */ |
|
20 |
+typedef unsigned long int UINT4; |
|
21 |
+ |
|
22 |
+/* PROTO_LIST is defined depending on how PROTOTYPES is defined above. |
|
23 |
+If using PROTOTYPES, then PROTO_LIST returns the list, otherwise it |
|
24 |
+ returns an empty list. |
|
25 |
+ */ |
|
26 |
+#if PROTOTYPES |
|
27 |
+#define PROTO_LIST(list) list |
|
28 |
+#else |
|
29 |
+#define PROTO_LIST(list) () |
|
30 |
+#endif |
|
31 |
+ |