anyexists = (lstat(realname, &lst) != -1);
- /* New case: if the file exists, just give up. */
+ /* If the temp file exists, give up. */
if (tmp && anyexists)
goto cleanup_and_exit;
if (ISSET(BACKUP_FILE) && !tmp && realexists &&
(append != 0 || ISSET(MARK_ISSET) ||
originalfilestat.st_mtime == st.st_mtime)) {
-
FILE *backup_file;
char *backupname;
struct utimbuf filetime;
}
/* Now open the file in place. Use O_EXCL if tmp is TRUE. This is
- * now copied from joe, because wiggy says so *shrug*. */
+ * copied from joe, because wiggy says so *shrug*. */
fd = open(realname, O_WRONLY | O_CREAT |
((append == 1) ? O_APPEND : (tmp ? O_EXCL : O_TRUNC)),
S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP | S_IROTH | S_IWOTH);
}
- *read_buff_ptr = (char)NULL;
+ *read_buff_ptr = '\0';
close(uniq_fd[0]);
/* Process the spelling errors. */
while (*read_buff_ptr != '\0') {
if ((*read_buff_ptr == '\n') || (*read_buff_ptr == '\r')) {
- *read_buff_ptr = (char)NULL;
+ *read_buff_ptr = '\0';
if (read_buff_word != read_buff_ptr) {
if (!do_int_spell_fix(read_buff_word)) {
read_buff_word = read_buff_ptr;