}
/* Write selected file paths to fd, linefeed separated */
-static ssize_t selectiontofd(int fd, uint *pcount)
+static size_t selectiontofd(int fd, uint *pcount)
{
uint lastpos, count = 0;
char *pbuf = pcopybuf;
- ssize_t pos = 0, len, r;
+ size_t pos = 0, len;
+ ssize_t r;
if (pcount)
*pcount = 0;
pos += len;
r = write(fd, pbuf, len);
- if (r != len)
+ if (r != (ssize_t)len)
return pos;
if (pos <= lastpos) {
static void showcplist(void)
{
int fd;
- ssize_t pos;
+ size_t pos;
if (!copybufpos)
return;
{
int count = 0;
char *pbuf = pcopybuf, *fname;
- ssize_t pos = 0, len, r;
+ size_t pos = 0, len, r;
int (*link_fn)(const char *, const char *) = NULL;
/* Check if selection is empty */