diff options
author | James Booth <boothj5@gmail.com> | 2014-04-02 21:01:20 +0100 |
---|---|---|
committer | James Booth <boothj5@gmail.com> | 2014-04-02 21:01:20 +0100 |
commit | a720ef262774e51066f5885c76deebde83dec74e (patch) | |
tree | ae401084d45f8edd57f602cbc53a2caf74e6c3eb /src/ui/statusbar.c | |
parent | e1db5318758dcfc72acb698938fc17c407a24cb5 (diff) | |
download | profani-tty-a720ef262774e51066f5885c76deebde83dec74e.tar.gz |
Removed strcpy calls
Diffstat (limited to 'src/ui/statusbar.c')
-rw-r--r-- | src/ui/statusbar.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/ui/statusbar.c b/src/ui/statusbar.c index eb39467b..bbb3b781 100644 --- a/src/ui/statusbar.c +++ b/src/ui/statusbar.c @@ -277,8 +277,7 @@ _status_bar_print_message(const char * const msg) if (message != NULL) { free(message); } - message = (char *) malloc(strlen(msg) + 1); - strcpy(message, msg); + message = strdup(msg); mvwprintw(status_bar, 0, 10, message); int cols = getmaxx(stdscr); |