mirror of
https://github.com/asterisk/asterisk.git
synced 2025-09-04 20:04:50 +00:00
fix usage of const char (bug #4388)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@5770 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
@@ -430,13 +430,13 @@ static int get_user_input(char *msg, char *buf, int buflen)
|
|||||||
newtComponent ok;
|
newtComponent ok;
|
||||||
newtComponent cancel;
|
newtComponent cancel;
|
||||||
newtComponent inpfield;
|
newtComponent inpfield;
|
||||||
const char *input;
|
char *input;
|
||||||
int res = -1;
|
int res = -1;
|
||||||
struct newtExitStruct es;
|
struct newtExitStruct es;
|
||||||
|
|
||||||
newtCenteredWindow(60,7, msg);
|
newtCenteredWindow(60,7, msg);
|
||||||
|
|
||||||
inpfield = newtEntry(5, 2, "", 50, &input, 0);
|
inpfield = newtEntry(5, 2, "", 50, (const char **)&input, 0);
|
||||||
ok = newtButton(22, 3, "OK");
|
ok = newtButton(22, 3, "OK");
|
||||||
cancel = newtButton(32, 3, "Cancel");
|
cancel = newtButton(32, 3, "Cancel");
|
||||||
form = newtForm(NULL, NULL, 0);
|
form = newtForm(NULL, NULL, 0);
|
||||||
@@ -553,8 +553,8 @@ static int login(char *hostname)
|
|||||||
newtComponent label;
|
newtComponent label;
|
||||||
newtComponent ulabel;
|
newtComponent ulabel;
|
||||||
newtComponent plabel;
|
newtComponent plabel;
|
||||||
const char *user;
|
char *user;
|
||||||
const char *pass;
|
char *pass;
|
||||||
struct message *m;
|
struct message *m;
|
||||||
struct newtExitStruct es;
|
struct newtExitStruct es;
|
||||||
char tmp[55];
|
char tmp[55];
|
||||||
@@ -603,8 +603,8 @@ static int login(char *hostname)
|
|||||||
ulabel = newtLabel(4,2,"Username:");
|
ulabel = newtLabel(4,2,"Username:");
|
||||||
plabel = newtLabel(4,3,"Password:");
|
plabel = newtLabel(4,3,"Password:");
|
||||||
|
|
||||||
username = newtEntry(14, 2, "", 20, &user, 0);
|
username = newtEntry(14, 2, "", 20, (const char **)&user, 0);
|
||||||
password = newtEntry(14, 3, "", 20, &pass, NEWT_FLAG_HIDDEN);
|
password = newtEntry(14, 3, "", 20, (const char **)&pass, NEWT_FLAG_HIDDEN);
|
||||||
|
|
||||||
form = newtForm(NULL, NULL, 0);
|
form = newtForm(NULL, NULL, 0);
|
||||||
newtFormAddComponents(form, username, password, login, cancel, label, ulabel, plabel,NULL);
|
newtFormAddComponents(form, username, password, login, cancel, label, ulabel, plabel,NULL);
|
||||||
|
Reference in New Issue
Block a user