in the input file. */
if (lseek (input_fd, file_pos, SEEK_SET) < 0)
- error (0, errno, _("%s: seek failed"), file);
+ error (0, errno, _("%s: seek failed"), quote (file));
if (safe_read (input_fd, G_buffer, saved_record_size) != saved_record_size)
{
- error (0, errno, "%s", file);
+ error (0, errno, "%s", quote (file));
return false;
}
file_pos = 0;
}
if (lseek (input_fd, file_pos, SEEK_SET) < 0)
- error (0, errno, _("%s: seek failed"), file);
+ error (0, errno, _("%s: seek failed"), quote (file));
/* Shift the pending record data right to make room for the new.
The source and destination regions probably overlap. */
if (safe_read (input_fd, G_buffer, read_size) != read_size)
{
- error (0, errno, "%s", file);
+ error (0, errno, "%s", quote (file));
return false;
}
}
tempfile = template;
fd = mkstemp (template);
if (fd == -1)
- error (EXIT_FAILURE, errno, "%s", tempfile);
+ error (EXIT_FAILURE, errno, "%s", quote (tempfile));
tmp = fdopen (fd, "w+");
if (tmp == NULL)
- error (EXIT_FAILURE, errno, "%s", tempfile);
+ error (EXIT_FAILURE, errno, "%s", quote (tempfile));
#if DONT_UNLINK_WHILE_OPEN
record_tempfile (tempfile, tmp);
if (bytes_read == 0)
break;
if (bytes_read == SAFE_READ_ERROR)
- error (EXIT_FAILURE, errno, _("%s: read error"), file);
+ error (EXIT_FAILURE, errno, _("%s: read error"), quote (file));
if (fwrite (G_buffer, 1, bytes_read, tmp) != bytes_read)
- error (EXIT_FAILURE, errno, "%s", tempfile);
+ error (EXIT_FAILURE, errno, "%s", quote (tempfile));
}
if (fflush (tmp) != 0)
- error (EXIT_FAILURE, errno, "%s", tempfile);
+ error (EXIT_FAILURE, errno, "%s", quote (tempfile));
SET_BINARY (fileno (tmp));
*g_tmp = tmp;