1
0
mirror of https://github.com/Llewellynvdm/conky.git synced 2024-11-17 18:45:10 +00:00

ignore EINTR select interrupt

git-svn-id: https://conky.svn.sourceforge.net/svnroot/conky/trunk/conky1@685 7f574dfc-610e-0410-a909-a81674777703
This commit is contained in:
Philip Kovacs 2006-08-11 19:13:32 +00:00
parent 49a440b4de
commit de4f298f3c

View File

@ -1,4 +1,5 @@
#include "conky.h"
#include <errno.h>
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
@ -81,7 +82,12 @@ char *get_hddtemp_info(char *dev, char *hostaddr, int port, char *unit)
i = select(sockfd+1, &rfds, NULL, NULL, &tv);
if (i == -1)
perror("select");
{
if (errno == EINTR) /* silently ignore interrupted system call */
goto out;
else
perror("select");
}
/* No data available */
if (i <= 0)