pld: fix new warnings from sparse

The new committed files add some warning from the static analyser
'sparse':
- Don't assign pointer to 0, use NULL.
- switch with no cases.

Fix them.

Change-Id: I2c02d629bd80b71c8e42553be5d9388bb9b6bcd0
Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
Reviewed-on: https://review.openocd.org/c/openocd/+/7668
Tested-by: jenkins
This commit is contained in:
Antonio Borneo
2023-05-06 16:19:55 +02:00
parent 247d8df314
commit cc29abe9d1
2 changed files with 1 additions and 3 deletions

View File

@@ -156,8 +156,6 @@ COMMAND_HANDLER(handle_pld_load_command)
if (retval != ERROR_OK) {
command_print(CMD, "failed loading file %s to pld device %u",
CMD_ARGV[1], dev_id);
switch (retval) {
}
return retval;
} else {
gettimeofday(&end, NULL);