Skip to content

Commit 8933f14

Browse files
committed
Fix CI follow-up failures
1 parent 7055381 commit 8933f14

2 files changed

Lines changed: 5 additions & 3 deletions

File tree

.github/workflows/ci.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,9 +96,12 @@ jobs:
9696
- name: Checkout
9797
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332
9898

99+
- name: Set up MSVC developer command prompt
100+
uses: ilammy/msvc-dev-cmd@v1
101+
99102
- name: Configure and build with MSVC
100103
run: |
101-
cmake -S . -B build -G "Visual Studio 17 2022" -A x64 -DMCBOR_BUILD_TESTS=ON
104+
cmake -S . -B build -G Ninja -DMCBOR_BUILD_TESTS=ON
102105
cmake --build build --config Release
103106
104107
arm-compile-only:

src/mcbor.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -361,13 +361,12 @@ mcbor_err_t mcbor_enc_null(mcbor_enc_t *enc)
361361

362362
mcbor_err_t mcbor_enc_float(mcbor_enc_t *enc, float value)
363363
{
364-
uint8_t tmp[5];
365-
366364
if (enc == NULL) return MCBOR_ERR_NULL;
367365
#if !MCBOR_ENABLE_FLOAT32
368366
(void)value;
369367
return MCBOR_ERR_UNSUPPORTED;
370368
#else
369+
uint8_t tmp[5];
371370

372371
tmp[0] = (uint8_t)(CBOR_MAJOR_SIMPLE | CBOR_INFO_4BYTE);
373372
put_u32(tmp + 1, float_to_bits(value));

0 commit comments

Comments
 (0)