Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
adam.huang
htop
Commits
c9cab824
Commit
c9cab824
authored
Aug 20, 2015
by
Hisham Muhammad
Browse files
Extra checks.
parent
5e4f1e46
Changes
3
Hide whitespace changes
Inline
Side-by-side
MainPanel.c
View file @
c9cab824
...
...
@@ -79,7 +79,7 @@ static HandlerResult MainPanel_eventHandler(Panel* super, int ch) {
}
else
{
reaction
|=
Action_setSortKey
(
settings
,
field
);
}
reaction
|=
HTOP_RECALCULATE
|
HTOP_REDRAW_BAR
;
reaction
|=
HTOP_RECALCULATE
|
HTOP_REDRAW_BAR
|
HTOP_SAVE_SETTINGS
;
result
=
HANDLED
;
}
else
if
(
ch
!=
ERR
&&
this
->
inc
->
active
)
{
bool
filterChanged
=
IncSet_handleKey
(
this
->
inc
,
ch
,
super
,
(
IncMode_GetPanelValue
)
MainPanel_getValue
,
NULL
);
...
...
RichString.c
View file @
c9cab824
...
...
@@ -84,7 +84,7 @@ static void RichString_extendLen(RichString* this, int len) {
this
->
chlen
=
len
;
}
#define RichString_setLen(this, len) do{ if(len < RICHSTRING_MAXLEN) { RichString_setChar(this,len,0); this->chlen=len; } else RichString_extendLen(this,len); }while(0)
#define RichString_setLen(this, len) do{ if(len <
RICHSTRING_MAXLEN && this->chlen <
RICHSTRING_MAXLEN) { RichString_setChar(this,len,0); this->chlen=len; } else RichString_extendLen(this,len); }while(0)
#ifdef HAVE_LIBNCURSESW
...
...
RichString.h
View file @
c9cab824
...
...
@@ -61,7 +61,7 @@ typedef struct RichString_ {
#define charBytes(n) (sizeof(CharType) * (n))
#define RichString_setLen(this, len) do{ if(len < RICHSTRING_MAXLEN) { RichString_setChar(this,len,0); this->chlen=len; } else RichString_extendLen(this,len); }while(0)
#define RichString_setLen(this, len) do{ if(len <
RICHSTRING_MAXLEN && this->chlen <
RICHSTRING_MAXLEN) { RichString_setChar(this,len,0); this->chlen=len; } else RichString_extendLen(this,len); }while(0)
#ifdef HAVE_LIBNCURSESW
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment