summaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
authorTom Rini <trini@ti.com>2014-08-25 08:34:39 -0400
committerTom Rini <trini@ti.com>2014-08-25 08:34:39 -0400
commit7bee1c91a94db19bd26f92cc67be35d3592c6429 (patch)
treea8e29376b47450c7a3b653e16df3ff9f603f2ca3 /tools
parent055626acba2754d3311204ad361b1828a4f8aaf6 (diff)
parent9fa7bbc126d697f1415adbac72bb7f6d978ff50d (diff)
Merge branch 'agust@denx.de' of git://git.denx.de/u-boot-staging
Diffstat (limited to 'tools')
-rw-r--r--tools/fit_info.c5
-rw-r--r--tools/image-host.c2
-rw-r--r--tools/mkimage.c2
3 files changed, 6 insertions, 3 deletions
diff --git a/tools/fit_info.c b/tools/fit_info.c
index 481ac6dd814..652abcd2bd1 100644
--- a/tools/fit_info.c
+++ b/tools/fit_info.c
@@ -48,10 +48,11 @@ int main(int argc, char **argv)
char *fdtfile = NULL;
char *nodename = NULL;
char *propertyname = NULL;
- char cmdname[50];
+ char cmdname[256];
int c;
- strcpy(cmdname, *argv);
+ strncpy(cmdname, *argv, sizeof(cmdname) - 1);
+ cmdname[sizeof(cmdname) - 1] = '\0';
while ((c = getopt(argc, argv, "f:n:p:")) != -1)
switch (c) {
case 'f':
diff --git a/tools/image-host.c b/tools/image-host.c
index 0eff720b621..7effb6cea59 100644
--- a/tools/image-host.c
+++ b/tools/image-host.c
@@ -689,7 +689,7 @@ int fit_add_verification_data(const char *keydir, void *keydest, void *fit,
confs_noffset = fdt_path_offset(fit, FIT_CONFS_PATH);
if (confs_noffset < 0) {
printf("Can't find images parent node '%s' (%s)\n",
- FIT_IMAGES_PATH, fdt_strerror(confs_noffset));
+ FIT_CONFS_PATH, fdt_strerror(confs_noffset));
return -ENOENT;
}
diff --git a/tools/mkimage.c b/tools/mkimage.c
index 123d0c7d938..c70408c9ba0 100644
--- a/tools/mkimage.c
+++ b/tools/mkimage.c
@@ -458,6 +458,7 @@ NXTARG: ;
#if defined(_POSIX_SYNCHRONIZED_IO) && \
!defined(__sun__) && \
!defined(__FreeBSD__) && \
+ !defined(__OpenBSD__) && \
!defined(__APPLE__)
(void) fdatasync (ifd);
#else
@@ -501,6 +502,7 @@ NXTARG: ;
#if defined(_POSIX_SYNCHRONIZED_IO) && \
!defined(__sun__) && \
!defined(__FreeBSD__) && \
+ !defined(__OpenBSD__) && \
!defined(__APPLE__)
(void) fdatasync (ifd);
#else