mail archive of the barebox mailing list
 help / color / mirror / Atom feed
* [PATCH] imd: fix missing error message
@ 2018-11-27 16:07 Thorsten K. Scherer
  2018-11-29  8:06 ` Sascha Hauer
  0 siblings, 1 reply; 2+ messages in thread
From: Thorsten K. Scherer @ 2018-11-27 16:07 UTC (permalink / raw)
  To: barebox; +Cc: Thorsten K. Scherer

imd -t just returns 'imd: error 61', if there is not tag for <type>

reference: common/imd.c:357 if (!imd) { ...
Signed-off-by: Thorsten K. Scherer <t.scherer@eckelmann.de>
---
 common/misc.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/common/misc.c b/common/misc.c
index 665f72be7..66aba534f 100644
--- a/common/misc.c
+++ b/common/misc.c
@@ -67,11 +67,11 @@ const char *strerror(int errnum)
 	case	ETIMEDOUT	: str = "Connection timed out"; break;
 	case	EPROBE_DEFER	: str = "Requested probe deferral"; break;
 	case	ELOOP		: str = "Too many symbolic links encountered"; break;
+	case	ENODATA		: str = "No data available"; break;
 #if 0 /* These are probably not needed */
 	case	ENOTBLK		: str = "Block device required"; break;
 	case	EFBIG		: str = "File too large"; break;
 	case	EBADSLT		: str = "Invalid slot"; break;
-	case	ENODATA		: str = "No data available"; break;
 	case	ETIME		: str = "Timer expired"; break;
 	case	ENONET		: str = "Machine is not on the network"; break;
 	case	EADV		: str = "Advertise error"; break;
-- 
2.19.1


-- 
Eckelmann AG
Vorstand: Dipl.-Ing. Peter Frankenbach (Sprecher) Dipl.-Wi.-Ing. Philipp Eckelmann
Dr.-Ing. Marco Münchhof Dr.-Ing. Frank Uhlemann
Vorsitzender des Aufsichtsrats: Hubertus G. Krossa
Stv. Vorsitzender des Aufsichtsrats: Dr.-Ing. Gerd Eckelmann
Sitz der Gesellschaft: Berliner Str. 161, 65205 Wiesbaden, Amtsgericht Wiesbaden HRB 12636
http://www.eckelmann.de

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [PATCH] imd: fix missing error message
  2018-11-27 16:07 [PATCH] imd: fix missing error message Thorsten K. Scherer
@ 2018-11-29  8:06 ` Sascha Hauer
  0 siblings, 0 replies; 2+ messages in thread
From: Sascha Hauer @ 2018-11-29  8:06 UTC (permalink / raw)
  To: Thorsten K. Scherer; +Cc: barebox

On Tue, Nov 27, 2018 at 05:07:30PM +0100, Thorsten K. Scherer wrote:
> imd -t just returns 'imd: error 61', if there is not tag for <type>
> 
> reference: common/imd.c:357 if (!imd) { ...
> Signed-off-by: Thorsten K. Scherer <t.scherer@eckelmann.de>
> ---
>  common/misc.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)

Applied, thanks

Sascha

> 
> diff --git a/common/misc.c b/common/misc.c
> index 665f72be7..66aba534f 100644
> --- a/common/misc.c
> +++ b/common/misc.c
> @@ -67,11 +67,11 @@ const char *strerror(int errnum)
>  	case	ETIMEDOUT	: str = "Connection timed out"; break;
>  	case	EPROBE_DEFER	: str = "Requested probe deferral"; break;
>  	case	ELOOP		: str = "Too many symbolic links encountered"; break;
> +	case	ENODATA		: str = "No data available"; break;
>  #if 0 /* These are probably not needed */
>  	case	ENOTBLK		: str = "Block device required"; break;
>  	case	EFBIG		: str = "File too large"; break;
>  	case	EBADSLT		: str = "Invalid slot"; break;
> -	case	ENODATA		: str = "No data available"; break;
>  	case	ETIME		: str = "Timer expired"; break;
>  	case	ENONET		: str = "Machine is not on the network"; break;
>  	case	EADV		: str = "Advertise error"; break;
> -- 
> 2.19.1
> 
> 
> -- 
> Eckelmann AG
> Vorstand: Dipl.-Ing. Peter Frankenbach (Sprecher) Dipl.-Wi.-Ing. Philipp Eckelmann
> Dr.-Ing. Marco Münchhof Dr.-Ing. Frank Uhlemann
> Vorsitzender des Aufsichtsrats: Hubertus G. Krossa
> Stv. Vorsitzender des Aufsichtsrats: Dr.-Ing. Gerd Eckelmann
> Sitz der Gesellschaft: Berliner Str. 161, 65205 Wiesbaden, Amtsgericht Wiesbaden HRB 12636
> http://www.eckelmann.de
> 
> _______________________________________________
> barebox mailing list
> barebox@lists.infradead.org
> http://lists.infradead.org/mailman/listinfo/barebox

-- 
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2018-11-29  8:06 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-11-27 16:07 [PATCH] imd: fix missing error message Thorsten K. Scherer
2018-11-29  8:06 ` Sascha Hauer

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox