#include "lib/mem.h"
#include "lib/intl.h"
#include "lib/str.h"
+#include "lib/debug.h"
#include <ctype.h>
#include <stdlib.h>
strfcpy (command, entry->composecommand, sizeof (command));
if (rfc1524_expand_filename (entry->nametemplate,
a->filename, newfile, sizeof (newfile))) {
- dprint (1, (debugfile, "oldfile: %s\t newfile: %s\n",
- a->filename, newfile));
+ debug_print (1, ("oldfile: %s\t newfile: %s\n", a->filename, newfile));
if (safe_symlink (a->filename, newfile) == -1) {
if (mutt_yesorno (_("Can't match nametemplate, continue?"), M_YES)
!= M_YES)
strfcpy (command, entry->editcommand, sizeof (command));
if (rfc1524_expand_filename (entry->nametemplate,
a->filename, newfile, sizeof (newfile))) {
- dprint (1, (debugfile, "oldfile: %s\t newfile: %s\n",
- a->filename, newfile));
+ debug_print (1, ("oldfile: %s\t newfile: %s\n", a->filename, newfile));
if (safe_symlink (a->filename, newfile) == -1) {
if (mutt_yesorno (_("Can't match nametemplate, continue?"), M_YES)
!= M_YES)
int lng;
if ((p = getenv ("MM_NOASK")) != NULL && *p) {
- if (safe_strcmp (p, "1") == 0)
+ if (mutt_strcmp (p, "1") == 0)
return (1);
strfcpy (tmp, p, sizeof (tmp));
}
}
else {
- lng = safe_strlen (p);
+ lng = mutt_strlen (p);
if (buf[lng] == '/' && safe_strncasecmp (buf, p, lng) == 0)
return (1);
}
int i;
for (; t; t = t->next) {
- i = safe_strlen (t->data) - 1;
+ i = mutt_strlen (t->data) - 1;
if ((i > 0 && t->data[i - 1] == '/' && t->data[i] == '*' &&
ascii_strncasecmp (type, t->data, i) == 0) ||
ascii_strcasecmp (type, t->data) == 0) {
n == TYPEMULTIPART ? "multipart" :
n == TYPETEXT ? "text" :
n == TYPEVIDEO ? "video" : "other", tmp.subtype);
- dprint (1, (debugfile, "mutt_check_lookup_list: \"%s\" -> %s\n",
- b->filename, type));
+ debug_print (1, ("\"%s\" -> %s\n", b->filename, type));
}
if (tmp.subtype)
FREE (&tmp.subtype);
}
for (; t; t = t->next) {
- i = safe_strlen (t->data) - 1;
+ i = mutt_strlen (t->data) - 1;
if ((i > 0 && t->data[i - 1] == '/' && t->data[i] == '*' &&
ascii_strncasecmp (type, t->data, i) == 0) ||
ascii_strcasecmp (type, t->data) == 0)
if (rfc1524_expand_filename (entry->nametemplate, fname,
tempfile, sizeof (tempfile))) {
- if (fp == NULL && safe_strcmp (tempfile, a->filename)) {
+ if (fp == NULL && mutt_strcmp (tempfile, a->filename)) {
/* send case: the file is already there */
if (safe_symlink (a->filename, tempfile) == -1) {
if (mutt_yesorno (_("Can't match nametemplate, continue?"), M_YES)
rfc1524_entry *entry;
int piped = FALSE;
- dprint (2, (debugfile, "Using mailcap...\n"));
+ debug_print (2, ("Using mailcap...\n"));
entry = rfc1524_new_entry ();
rfc1524_mailcap_lookup (a, type, entry, M_PRINT);
mutt_mktemp (newfile);
if (mutt_decode_save_attachment (fp, a, newfile, M_PRINTING, 0) == 0) {
- dprint (2,
- (debugfile, "successfully decoded %s type attachment to %s\n",
+ debug_print (2, ("successfully decoded %s type attachment to %s\n",
type, newfile));
if ((ifp = fopen (newfile, "r")) == NULL) {
goto bail0;
}
- dprint (2, (debugfile, "successfully opened %s read-only\n", newfile));
+ debug_print (2, ("successfully opened %s read-only\n", newfile));
mutt_endwin (NULL);
if ((thepid =
goto bail0;
}
- dprint (2, (debugfile, "Filter created.\n"));
+ debug_print (2, ("Filter created.\n"));
mutt_copy_stream (ifp, fpout);