projects
/
apps
/
madmutt.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
oops, ascii_strncasecmp tried to compare one byte too far
[apps/madmutt.git]
/
lib-ui
/
status.c
diff --git
a/lib-ui/status.c
b/lib-ui/status.c
index
2dbf7e7
..
b2b3835
100644
(file)
--- a/
lib-ui/status.c
+++ b/
lib-ui/status.c
@@
-11,10
+11,10
@@
#include <lib-ui/curses.h>
#include <lib-ui/menu.h>
#include <lib-ui/curses.h>
#include <lib-ui/menu.h>
+#include <lib-mx/mx.h>
#include "mutt.h"
#include "sort.h"
#include "mutt.h"
#include "sort.h"
-#include "mx.h"
#include "buffy.h"
#define SW (option(OPTMBOXPANE)?SidebarWidth:0)
#include "buffy.h"
#define SW (option(OPTMBOXPANE)?SidebarWidth:0)
@@
-52,7
+52,7
@@
static const char *status_format_str (char *buf, ssize_t buflen, char op,
const char *elsestring,
unsigned long data, format_flag flags)
{
const char *elsestring,
unsigned long data, format_flag flags)
{
- char fmt[S
HORT_STRING], tmp[SHORT_
STRING];
+ char fmt[S
TRING], tmp[
STRING];
const char *cp, *p;
int count, optional = (flags & M_FORMAT_OPTIONAL);
MUTTMENU *menu = (MUTTMENU *) data;
const char *cp, *p;
int count, optional = (flags & M_FORMAT_OPTIONAL);
MUTTMENU *menu = (MUTTMENU *) data;
@@
-70,7
+70,7
@@
static const char *status_format_str (char *buf, ssize_t buflen, char op,
case 'B':
snprintf (fmt, sizeof (fmt), "%%%ss", prefix);
case 'B':
snprintf (fmt, sizeof (fmt), "%%%ss", prefix);
- if (Context && Context->c
ompress
info && Context->realpath) {
+ if (Context && Context->cinfo && Context->realpath) {
if ((p = strrchr (Context->realpath, '/')))
m_strcpy(tmp, sizeof(tmp), p + 1);
else
if ((p = strrchr (Context->realpath, '/')))
m_strcpy(tmp, sizeof(tmp), p + 1);
else
@@
-104,17
+104,16
@@
static const char *status_format_str (char *buf, ssize_t buflen, char op,
case 'f':
snprintf (fmt, sizeof (fmt), "%%%ss", prefix);
case 'f':
snprintf (fmt, sizeof (fmt), "%%%ss", prefix);
- if (Context && Context->c
ompress
info && Context->realpath) {
+ if (Context && Context->cinfo && Context->realpath) {
m_strcpy(tmp, sizeof(tmp), Context->realpath);
mutt_pretty_mailbox (tmp);
m_strcpy(tmp, sizeof(tmp), Context->realpath);
mutt_pretty_mailbox (tmp);
- }
- else
+ } else
if (Context && Context->path) {
m_strcpy(tmp, sizeof(tmp), Context->path);
mutt_pretty_mailbox (tmp);
if (Context && Context->path) {
m_strcpy(tmp, sizeof(tmp), Context->path);
mutt_pretty_mailbox (tmp);
- }
- else
+ } else {
m_strcpy(tmp, sizeof(tmp), _("(no mailbox)"));
m_strcpy(tmp, sizeof(tmp), _("(no mailbox)"));
+ }
snprintf (buf, buflen, fmt, tmp);
break;
snprintf (buf, buflen, fmt, tmp);
break;