- Timestamp:
- 11/01/09 12:05:07 (3 years ago)
- Children:
- 079f92a31281573b8a7b152b1730e7a349ac6365
- Parents:
- a7f6dd2b9fc3f8ad29a05135c99288156961329b
- git-author:
- Pierre-Alexandre Meyer <pierre@mouraf.org> / 2009-10-31T22:32:26Z-0700
- git-committer:
- Erwan Velu <erwan.velu@free.fr> / 2009-11-01T13:05:07Z+0100
- Files:
-
- 1 modified
-
com32/hdt/hdt-cli-hdt.c (modified) (9 diffs)
Legend:
- Unmodified
- Added
- Removed
-
com32/hdt/hdt-cli-hdt.c
ra7f6dd rdff898 53 53 int i = 0; 54 54 55 printf("Available modes:\n"); 55 reset_more_printf(); 56 more_printf("Available modes:\n"); 56 57 while (list_modes[i]) { 57 printf("%s ", list_modes[i]->name);58 more_printf("%s ", list_modes[i]->name); 58 59 i++; 59 60 } 60 printf("\n");61 more_printf("\n"); 61 62 } 62 63 … … 71 72 cli_mode_t new_mode; 72 73 74 reset_more_printf(); 73 75 if (argc <= 0) { 74 printf("Which mode?\n");76 more_printf("Which mode?\n"); 75 77 return; 76 78 } … … 118 120 find_cli_mode_descr(hdt_cli.mode, ¤t_mode); 119 121 120 printf("Available commands are:\n"); 122 reset_more_printf(); 123 more_printf("Available commands are:\n"); 121 124 122 125 /* List first default modules of the mode */ … … 124 127 current_mode->default_modules->modules) { 125 128 while (current_mode->default_modules->modules[j].name) { 126 printf("%s ",129 more_printf("%s ", 127 130 current_mode->default_modules->modules[j].name); 128 131 j++; 129 132 } 130 printf("\n");133 more_printf("\n"); 131 134 } 132 135 … … 134 137 if (current_mode->show_modules && 135 138 current_mode->show_modules->modules) { 136 printf("\nshow commands:\n");139 more_printf("\nshow commands:\n"); 137 140 j = 0; 138 141 while (current_mode->show_modules->modules[j].name) { 139 printf("%s ",142 more_printf("%s ", 140 143 current_mode->show_modules->modules[j].name); 141 144 j++; 142 145 } 143 printf("\n");146 more_printf("\n"); 144 147 } 145 148 … … 147 150 if (current_mode->set_modules && 148 151 current_mode->set_modules->modules) { 149 printf("\nset commands:\n");152 more_printf("\nset commands:\n"); 150 153 j = 0; 151 154 while (current_mode->set_modules->modules[j].name) { 152 printf("%s ",155 more_printf("%s ", 153 156 current_mode->set_modules->modules[j].name); 154 157 j++; 155 158 } 156 printf("\n");159 more_printf("\n"); 157 160 } 158 161 … … 174 177 &associated_module); 175 178 if (associated_module == NULL) 176 printf("%s ",179 more_printf("%s ", 177 180 hdt_mode.default_modules->modules[j].name); 178 181 j++; 179 182 } 180 printf("\n");181 } 182 183 printf("\n");183 more_printf("\n"); 184 } 185 186 more_printf("\n"); 184 187 main_show_modes(argc, argv, hardware); 185 188 } … … 207 210 detect_dmi(hardware); 208 211 cpu_detect(hardware); 212 reset_more_printf(); 209 213 clear_screen(); 210 214 main_show_cpu(argc, argv, hardware); … … 237 241 struct s_hardware *hardware __unused) 238 242 { 239 printf("HDT\n"); 240 printf(" Product : %s\n", PRODUCT_NAME); 241 printf(" Version : %s\n", VERSION); 242 printf(" Author : %s\n", AUTHOR); 243 printf(" Contact : %s\n", CONTACT); 243 reset_more_printf(); 244 more_printf("HDT\n"); 245 more_printf(" Product : %s\n", PRODUCT_NAME); 246 more_printf(" Version : %s\n", VERSION); 247 more_printf(" Author : %s\n", AUTHOR); 248 more_printf(" Contact : %s\n", CONTACT); 244 249 char *contributors[NB_CONTRIBUTORS] = CONTRIBUTORS; 245 250 for (int c = 0; c < NB_CONTRIBUTORS; c++) { 246 printf(" Contributor : %s\n", contributors[c]);251 more_printf(" Contributor : %s\n", contributors[c]); 247 252 } 248 253 }
