[syslinux:master] libupload: Use new TFTP OK status definition

syslinux-bot for Gene Cumm gene.cumm at gmail.com
Sat Apr 23 18:12:03 PDT 2016


Commit-ID:  a615768ccafaffc444a808bffc0479ab7dc9efee
Gitweb:     http://www.syslinux.org/commit/a615768ccafaffc444a808bffc0479ab7dc9efee
Author:     Gene Cumm <gene.cumm at gmail.com>
AuthorDate: Sat, 23 Apr 2016 21:10:41 -0400
Committer:  Gene Cumm <gene.cumm at gmail.com>
CommitDate: Sat, 23 Apr 2016 21:10:41 -0400

libupload: Use new TFTP OK status definition

FTBFS: com32/hdt/hdt-dump.c:227:39: error: ‘TFTP_OK’ undeclared
  (first use in this function)

Signed-off-by: Gene Cumm <gene.cumm at gmail.com>

---
 com32/hdt/hdt-dump.c          | 2 +-
 com32/libupload/upload_tftp.c | 4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/com32/hdt/hdt-dump.c b/com32/hdt/hdt-dump.c
index 03049d9..17bcc25 100644
--- a/com32/hdt/hdt-dump.c
+++ b/com32/hdt/hdt-dump.c
@@ -224,7 +224,7 @@ void dump(struct s_hardware *hardware)
     /* We close & flush the file to send */
     cpio_close(upload);
 
-    if ((err = flush_data(upload)) != TFTP_OK) {
+    if ((err = flush_data(upload)) != TFTP_ERR_OK) {
 	/* As we manage a tftp connection, let's display the associated error message */
 	more_printf("Dump failed !\n");
 	more_printf("TFTP ERROR on  : %s:/%s \n", hardware->tftp_ip, filename);
diff --git a/com32/libupload/upload_tftp.c b/com32/libupload/upload_tftp.c
index 8ca8752..1e0b070 100644
--- a/com32/libupload/upload_tftp.c
+++ b/com32/libupload/upload_tftp.c
@@ -52,13 +52,13 @@ static int upload_tftp_write(struct upload_backend *be) {
 
     parse_url(&url, url_path);
     err = -url_set_ip(&url);
-    if (err != TFTP_OK)
+    if (err != TFTP_ERR_OK)
 	return err;
 
     dprintf("Connecting to %s to send %s\n", url.host, url.path);
     err = -tftp_put(&url, 0, &inode, NULL, be->outbuf, be->zbytes);
 
-    if (err != TFTP_OK) {
+    if (err != TFTP_ERR_OK) {
 	printf("upload_tftp_write: TFTP server returned error %d : %s\n",
 	       err, tftp_string_error_message[err]);
     }


More information about the Syslinux-commits mailing list