* SPDX-License-Identifier: GPL-2.0
*/
-#include "common.h"
-#include <string.h>
-#include <stdlib.h>
-#include <stdbool.h>
+#include "env.h"
#include <avr/eeprom.h>
#include "config.h"
#include "debug.h"
-#include "xmalloc.h"
#include "crc.h"
#include "getopt-min.h"
-#include "command.h"
-#include "env.h"
#define ENV_SIZE (CONFIG_ENV_SIZE - sizeof(uint16_t) -1)
return -1;
}
- np = (char *) xmalloc(len+1);
+ np = (char *) malloc(len+1);
if (np == NULL) {
printf_P(PSTR("## Can't malloc %d bytes\n"), len+1);
return 1;
for (i = 2, len += 1; i < argc; ++i)
len += strlen(argv[i]) + 1;
- value = xmalloc(len);
+ value = malloc(len);
if (value == NULL) {
printf_P(PSTR("## Can't malloc %d bytes\n"), len);
return CMD_RET_FAILURE;