[PATCH 1/1] Remove dead code in util.c

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




From: Heinrich Schuchardt <xypron.glpk@xxxxxx>

xrealloc never returns null

Signed-off-by: Heinrich Schuchardt <xypron.glpk@xxxxxx>
---
 util.c |    4 ----
 1 file changed, 4 deletions(-)

diff --git a/util.c b/util.c
index be67836..1ce8b97 100644
--- a/util.c
+++ b/util.c
@@ -219,10 +219,6 @@ int utilfdt_read_err_len(const char *filename, char **buffp, off_t *len)
 		if (offset == bufsize) {
 			bufsize *= 2;
 			buf = xrealloc(buf, bufsize);
-			if (!buf) {
-				ret = ENOMEM;
-				break;
-			}
 		}
 
 		ret = read(fd, &buf[offset], bufsize - offset);
-- 
1.7.10.4

--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Device Tree Compilter]     [Device Tree Spec]     [Linux Driver Backports]     [Video for Linux]     [Linux USB Devel]     [Linux PCI Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Yosemite Backpacking]
  Powered by Linux