repositories
/
TD_C.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Be more explicit in Makefiles about external libraries linking
[TD_C.git]
/
TP_13
/
exo2
/
src
/
main.c
diff --git
a/TP_13/exo2/src/main.c
b/TP_13/exo2/src/main.c
index 854ddb9c1e52d9dd6a90622eda0b11120080e55b..bdc1ccd881172d9e3c206cd493e9001a6054e05d 100644
(file)
--- a/
TP_13/exo2/src/main.c
+++ b/
TP_13/exo2/src/main.c
@@
-17,6
+17,12
@@
int main() {
char* exit_msg = malloc(str_max_length * sizeof(char));
initscr();
char* exit_msg = malloc(str_max_length * sizeof(char));
initscr();
+ if (has_colors() == false) {
+ endwin();
+ printf("Votre terminal ne supporte pas les couleurs.\n");
+ exit(EXIT_FAILURE);
+ }
+ start_color();
getmaxyx(stdscr, row, col);
noecho();
curs_set(0);
getmaxyx(stdscr, row, col);
noecho();
curs_set(0);