diff options
author | Rene Mayrhofer <rene@mayrhofer.eu.org> | 2009-06-23 11:25:24 +0000 |
---|---|---|
committer | Rene Mayrhofer <rene@mayrhofer.eu.org> | 2009-06-23 11:25:24 +0000 |
commit | 41787e147279ff0695e9d759487266a60b80867b (patch) | |
tree | 8f28566c8fd7106c80d2536d2df540dbb4499cc5 /src/libstrongswan/asn1/oid.pl | |
parent | c3e7f611ea8273c6b3909cb006ade4903a74aad0 (diff) | |
download | vyos-strongswan-41787e147279ff0695e9d759487266a60b80867b.tar.gz vyos-strongswan-41787e147279ff0695e9d759487266a60b80867b.zip |
[svn-upgrade] Integrating new upstream version, strongswan (4.3.2)
Diffstat (limited to 'src/libstrongswan/asn1/oid.pl')
-rw-r--r-- | src/libstrongswan/asn1/oid.pl | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/libstrongswan/asn1/oid.pl b/src/libstrongswan/asn1/oid.pl index 373101cc0..ed26febc9 100644 --- a/src/libstrongswan/asn1/oid.pl +++ b/src/libstrongswan/asn1/oid.pl @@ -32,12 +32,14 @@ print OID_H "/* Object identifiers (OIDs) used by strongSwan\n", " * ", $automatic, "\n", " * ", $warning, "\n", " */\n\n", + "#include <sys/types.h>\n\n", "#ifndef OID_H_\n", "#define OID_H_\n\n", "typedef struct {\n", " u_char octet;\n", " u_int next;\n", " u_int down;\n", + " u_int level;\n", " const u_char *name;\n", "} oid_t;\n", "\n", @@ -77,6 +79,8 @@ while ($line = <SRC>) $counter++; } +printf OID_H "\n#define OID_MAX%s%d\n", "\t" x 8, $counter; + print OID_H "\n#endif /* OID_H_ */\n"; close SRC; @@ -113,12 +117,13 @@ for ($c = 0; $c < $counter; $c++) } } - printf OID_C " {%s%s,%s%3d, %d, %s%s}%s /* %3d */\n" + printf OID_C " {%s%s,%s%3d, %d, %2d, %s%s}%s /* %3d */\n" ,' ' x @order[$c] , @octet[$c] , ' ' x (1 + $max_order - @order[$c]) , @next[$c] , @order[$c+1] > @order[$c] + , @order[$c] / 2 , @name[$c] , ' ' x ($max_name - length(@name[$c])) , $c != $counter-1 ? "," : " " |