mirror of
https://github.com/Llewellynvdm/conky.git
synced 2024-12-27 04:32:55 +00:00
Revert "Fix array bounds problem in hddtemp code."
This reverts commit d0de7cbd63
.
This commit is contained in:
parent
c92272a943
commit
1c4044252c
@ -91,7 +91,6 @@ static char *read_hdd_val(const char *line)
|
||||
return ret;
|
||||
/* read the device */
|
||||
dev = ++p;
|
||||
if (!p) return ret;
|
||||
if (!(p = strchr(p, line_s[0])))
|
||||
return ret;
|
||||
*(p++) = '\0';
|
||||
@ -198,7 +197,6 @@ char *get_hddtemp_info(char *dev, char *hostaddr, int port)
|
||||
if ((p = read_hdd_val(buf)) == NULL)
|
||||
goto GET_OUT;
|
||||
do {
|
||||
if (p >= buf + BUFLEN) break;
|
||||
if (!strncmp(dev, p, strlen(dev)))
|
||||
asprintf(&r, "%s", p + strlen(dev));
|
||||
free(p);
|
||||
|
Loading…
Reference in New Issue
Block a user