Skip to content

Commit

Permalink
lp503x_main: Minor fix
Browse files Browse the repository at this point in the history
Signed-off-by: zhangshoukui <[email protected]>
  • Loading branch information
Zhangshoukui committed Jan 16, 2025
1 parent 14fa7d2 commit e2d539e
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions examples/lp503x/lp503x_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -625,20 +625,19 @@ static int lp503x_cmd_help(FAR char *parg)

int main(int argc, FAR char *argv[])
{
bool running;
char buffer[LINE_MAX];
FAR char *cmd;
FAR char *arg;
bool running;
int len;
int x;
char *cmd;
char *arg;

fd = open(CONFIG_EXAMPLES_LP503X_DEVPATH, O_CREAT);
if (fd < 0)
{
fprintf(stderr, "ERROR: Failed to open %s: %d\n",
CONFIG_EXAMPLES_LP503X_DEVPATH, errno);
close(fd);
return ENODEV;
return -ENODEV;
}

running = true;
Expand Down

0 comments on commit e2d539e

Please sign in to comment.