Commit Graph

583 Commits

Author SHA1 Message Date
Lev Walkin b4776ff2ee bring OER in non-OER modes (temporary) 2017-08-02 13:32:21 -07:00
Lev Walkin 890e6038cc OER encode SEQUENCE 2017-08-02 13:32:20 -07:00
Lev Walkin 602aacb5ea simplify dependencies 2017-08-02 13:32:20 -07:00
Lev Walkin 9ae018ee9c Native Integer OER support 2017-08-02 13:32:20 -07:00
Lev Walkin 3fd85d8ae4 PER aligned flush 2017-08-02 13:32:19 -07:00
Lev Walkin f573ebbd98 CODEC-OER for OER file dependencies 2017-08-02 13:32:19 -07:00
Lev Walkin 51a1f3f68b rename slurp->skip 2017-08-02 13:32:19 -07:00
Lev Walkin 20ea852177 add OER open type decoder 2017-08-02 13:32:19 -07:00
Lev Walkin 39837e6c26 safety 2017-08-02 13:32:19 -07:00
Lev Walkin d88bea9b11 add OER SEQUENCE decoder 2017-08-02 13:32:19 -07:00
Lev Walkin b33425f16b fix OER stubs order 2017-08-02 13:32:18 -07:00
Lev Walkin cc9b3aebdc test OER encoding over the INTEGER value range 2017-08-02 13:32:18 -07:00
Lev Walkin 527497f791 enable OER encoder 2017-08-02 13:32:18 -07:00
Lev Walkin 486fd5cbf5 add encode check (fails yet) 2017-08-02 13:32:17 -07:00
Lev Walkin fcfe19b2ae add some INTEGER OER encoding code 2017-08-02 13:32:17 -07:00
Lev Walkin e4d8c92142 add some support for INTEGER decoding 2017-08-02 13:32:17 -07:00
Lev Walkin 54f3451609 add failed test for INTEGER decode OER 2017-08-02 13:32:17 -07:00
Lev Walkin 4558ad0629 add OER encoder helpers 2017-08-02 13:32:17 -07:00
Lev Walkin 099da6ffc1 no C support code yet 2017-08-02 13:32:17 -07:00
Lev Walkin ed3a4ae4ac INTEGER decoding stub 2017-08-02 13:32:17 -07:00
Lev Walkin 7678076f34 introduce oer constraint code 2017-08-02 13:32:16 -07:00
Lev Walkin e7b73c40da oer support code 2017-08-02 13:32:16 -07:00
Lev Walkin cc1594746a add skeleton OER stubs 2017-08-02 13:32:16 -07:00
Lev Walkin ea200d9be7 Merge pull request #155 from johvik/master
Add const to strings in skeletons/
2017-08-02 13:21:59 -07:00
Lev Walkin 80334ed5db guard PER references 2017-07-06 07:28:21 -07:00
Lev Walkin 5d9e3c50b5 remove warning 2017-07-05 16:25:24 -07:00
Lev Walkin 72ec909738 introduce intmax_t 2017-07-05 05:49:12 -07:00
Lev Walkin 5c9c34261c change quotes 2017-07-05 05:48:05 -07:00
Lev Walkin b02145b206 stck initialized later 2017-06-28 08:52:07 -07:00
Lev Walkin 7e0ab8821d remove unreferenced var 2017-06-28 08:47:47 -07:00
Lev Walkin 39248ffb98 Merge pull request #157 from johvik/prototype
Missing void in _new_stack()
2017-06-27 08:35:28 -07:00
johvik 28268d9bf2 Missing void in _new_stack()
This removes the GCC warning:
"warning: function declaration isn’t a prototype [-Wstrict-prototypes]"
2017-05-09 10:28:59 +02:00
johvik 5f619fb258 Add const to strings in skeletons/
This removes the GCC warning:
"warning: initialization discards ‘const’ qualifier from pointer
target type [-Wdiscarded-qualifiers]"
from BIT_STRING.c and ber_tlv_tag.c.
2017-05-09 09:05:04 +02:00
Bi-Ruei, Chiu c46137bddd Merge velichkov's commit 598e7b45... to mouse07410's asn1c repository
Excerpt from commit log :

  Do not generate coverage data for the test C code
  When compiling tests remove the CODE_COVERAGE_CFLAGS flags from CFLAGS

and also add

  CFLAGS = $(filter-out $(CODE_COVERAGE_CFLAGS), @CFLAGS@)

to 'skeleton/Makefile.am' to avoid compilation error in vlm's repository.
2017-05-08 17:04:38 +08:00
Lev Walkin 46fc2bd8c4 support for C++ 2017-03-26 05:49:10 -07:00
Simo Sorce 798bacfbbe Remove misleading continue statement
The RETURN macro unconditionally returns so there is no chance to "continue".
Unreachable, fund by coverity.

Signed-off-by: Simo Sorce <simo@redhat.com>
2017-03-26 05:00:01 -07:00
Simo Sorce cd943c243d The Left variable should be a positive integer
The variable Left is supposed to hold only a positive quantity and was
being passed into functions that accept only size_t as input causing coverity
to throw a fit. Using a size_t type for Left works just fine.
Negative Returns, found by coverity.
2017-03-26 05:00:01 -07:00
Simo Sorce e6b650a0d9 Check and propagate error
per_put_few_bits should be checked for errors.
Checked return, fund by coverity.

Signed-off-by: Simo Sorce <simo@redhat.com>
2017-03-26 05:00:01 -07:00
Simo Sorce 9cbd9b850e Remove dead code.
On the previous line we return if cb is Null, so testing cb is worthless.
Dead code, found by coverity.

Signed-off-by: Simo Sorce <simo@redhat.com>
2017-03-26 04:58:06 -07:00
Vasil Velichkov adf6594053 Fix "_BSD_SOURCE" redefined warning
../../skeletons/GeneralizedTime.c:7:0: warning: "_BSD_SOURCE" redefined [enabled by default]
 #define _BSD_SOURCE     /* for timegm(3) */
2017-03-26 04:47:14 -07:00
Vasil Velichkov d82f77b2d2 Fix few duplicate 'const' warnings
error: duplicate 'const' [-Werror=edantic]
2017-03-26 04:46:00 -07:00
Vasil Velichkov e318759ef2 Add code coverage using lcov and gcov
To generate the code coverage report you need gcov and lcov installed
and then execute

 ./configure --enable-code-coverage
 make check-code-coverage

 Writing directory view page.
 Overall coverage rate:
   lines......: 76.5% (10519 of 13759 lines)
   functions..: 85.5% (491 of 574 functions)
   branches...: 57.5% (7040 of 12250 branches)
 file:///home/user/asn1c/asn1c-0.9.28-coverage/index.html

Open the index.html with a web browser
2017-03-26 04:42:26 -07:00
Lev Walkin e088a2b07a Merge branch 'master' into windows-universal-build 2017-03-26 04:04:32 -07:00
Lev Walkin 9e0bf1b87a refer to defined macro 2017-03-26 04:03:43 -07:00
Lev Walkin d27d5b5e72 Merge pull request #89 from brchiu/unify_specs_variable_name
Unify the naming of asn_OCTET_STRING_specifics_t variables
2017-03-26 03:50:37 -07:00
Lev Walkin 9413414cdd better dir 2017-03-26 03:11:02 -07:00
Lev Walkin f3ecbcaaf2 Merge pull request #75 from devjoa/master
Fixed debug logging bug in per_get_few_bits.
2016-12-02 11:25:05 -08:00
Erika Thorsen 2aa10de1a8 Only remove __attributes__ in Windows builds 2016-11-28 08:35:08 +01:00
Erika Thorsen afea72f494 Include stdint.h instead of typedef types if Visual Studio 2010 or newer. 2016-11-14 07:55:19 +01:00
Erika Thorsen 8723dc7337 Removed __attribute__ since its not Windows compliant 2016-11-14 07:54:43 +01:00