Skip to content

Commit

Permalink
Fix build issues on Alpine CI
Browse files Browse the repository at this point in the history
  • Loading branch information
jeanthom committed Dec 13, 2022
1 parent eb78a19 commit b9c92f5
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
2 changes: 1 addition & 1 deletion Makefile.stm32f1
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ UCMX_DIR := $(realpath unicore-mx)
UCMX_INCLUDE_DIR := $(UCMX_DIR)/include
UCMX_LIB_DIR := $(UCMX_DIR)/lib

CFLAGS = -g -O2
CFLAGS = -g -O2 -std=c99
CFLAGS += -Wall -Wextra -Werror
CFLAGS += -fno-common -ffunction-sections -fdata-sections
CFLAGS += -std=gnu11
Expand Down
10 changes: 6 additions & 4 deletions src/cmd.c
Original file line number Diff line number Diff line change
Expand Up @@ -138,10 +138,12 @@ uint8_t cmd_handle(usbd_device *usbd_dev, const usbd_transfer *transfer) {
break;

case CMD_XFER:
bool no_read = *commands & NO_READ;
uint32_t trbytes = cmd_xfer(commands, *commands & EXTEND_LENGTH, no_read, output_buffer);
commands += 1 + trbytes;
output_buffer += (no_read ? 0 : trbytes);
{
bool no_read = *commands & NO_READ;
uint32_t trbytes = cmd_xfer(commands, *commands & EXTEND_LENGTH, no_read, output_buffer);
commands += 1 + trbytes;
output_buffer += (no_read ? 0 : trbytes);
}
break;

case CMD_SETSIG:
Expand Down

0 comments on commit b9c92f5

Please sign in to comment.