summaryrefslogtreecommitdiff
path: root/tools/asn1_compiler.c
AgeCommit message (Collapse)Author
2026-04-24tools/asn1_compiler: avoid -Wdiscarded-qualifiersHeinrich Schuchardt
Building with GCC 15.2 results in warnings: tools/asn1_compiler.c: In function ‘tokenise’: tools/asn1_compiler.c:442:37: warning: assignment discards ‘const’ qualifier from pointer target type [-Wdiscarded-qualifiers] 442 | dir = bsearch(&tokens[tix], directives, | ^ tools/asn1_compiler.c: In function ‘main’: tools/asn1_compiler.c:632:11: warning: assignment discards ‘const’ qualifier from pointer target type [-Wdiscarded-qualifiers] 632 | p = strchr(grammar_name, '.'); | ^ bsearch() is defined as void *bsearch(size_t n, size_t size; const void key[size], const void base[size * n], size_t n, size_t size, typeof(int (const void [size], const void [size])) *compar); * Use the correct type for dir. strchr() is defined as char *strchr(const char *s, int c). * Use a conversion for the assignment to p. Signed-off-by: Heinrich Schuchardt <[email protected]> Reviewed-by: Simon Glass <[email protected]>
2021-09-30WS cleanup: remove trailing white spaceWolfgang Denk
Signed-off-by: Wolfgang Denk <[email protected]> Reviewed-by: Simon Glass <[email protected]>
2019-12-06cmd: add asn1_compilerAKASHI Takahiro
Imported from linux kernel v5.3: asn1.h without changes asn1_ber_bytecode.h without changes asn1_decoder.h without changes asn1_compiler.c without changes This host command will be used to create a ASN1 parser, for example, for pkcs7 messages or x509 certificates. More specifically, it will generate *byte code* which will be interpreted by asn1 decoder library. Signed-off-by: AKASHI Takahiro <[email protected]> Reviewed-by: Heinrich Schuchardt <[email protected]>