|
|
@ -209,11 +209,14 @@ main_window *setup_window(){
|
|
|
|
|
|
|
|
|
|
|
|
void main_update_dispatcher() {
|
|
|
|
void main_update_dispatcher() {
|
|
|
|
int second = gtk_spin_button_get_value(GTK_SPIN_BUTTON(widgets->spinUpdateDispatcher));
|
|
|
|
int second = gtk_spin_button_get_value(GTK_SPIN_BUTTON(widgets->spinUpdateDispatcher));
|
|
|
|
char* str_second = yon_char_from_int(second);
|
|
|
|
if (second>0) {
|
|
|
|
char *cmd = yon_char_get_augumented("systemd-cgtop -d ", str_second);
|
|
|
|
char* str_second = yon_char_from_int(second);
|
|
|
|
yon_terminal_integrated_launch(widgets->vteDispatcher, cmd, NULL, NULL);
|
|
|
|
char *cmd = yon_char_get_augumented("systemd-cgtop -d ", str_second);
|
|
|
|
free(str_second);
|
|
|
|
yon_terminal_integrated_launch(widgets->vteDispatcher, cmd, NULL, NULL);
|
|
|
|
free(cmd);
|
|
|
|
free(str_second);
|
|
|
|
|
|
|
|
free(cmd);
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
void main_update_processes() {
|
|
|
|
void main_update_processes() {
|
|
|
@ -438,14 +441,12 @@ void str_split_value(char* values, int index) {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
init_cfg_array(index);
|
|
|
|
init_cfg_array(index);
|
|
|
|
char* value_i = NULL;
|
|
|
|
char* value_i = NULL;
|
|
|
|
for (int index_1 = 0; index_1 < size; index_1++) {
|
|
|
|
int index_1 = 0;
|
|
|
|
|
|
|
|
for (index_1=0; index_1 < size; index_1++) {
|
|
|
|
value = yon_char_new(arr_values[index_1]);
|
|
|
|
value = yon_char_new(arr_values[index_1]);
|
|
|
|
key = yon_char_divide_search(value, "=", -1);
|
|
|
|
key = yon_char_divide_search(value, "=", -1);
|
|
|
|
if (yon_char_find_count(key, "IOReadBandwidthMax") != 0) {
|
|
|
|
if (strstr(key, "IOReadBandwidthMax") || strstr(key, "IOWriteBandwidthMax")) {
|
|
|
|
get_param_io_limit(arr_values, index_1, size,index, "IOReadBandwidthMax");
|
|
|
|
break;
|
|
|
|
}
|
|
|
|
|
|
|
|
if (yon_char_find_count(key, "IOWriteBandwidthMax") != 0) {
|
|
|
|
|
|
|
|
get_param_io_limit(arr_values, index_1, size,index, "IOWriteBandwidthMax");
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if (yon_char_find_count(key, "MemoryHigh") != 0) {
|
|
|
|
if (yon_char_find_count(key, "MemoryHigh") != 0) {
|
|
|
|
philos_set_pow_size_memory(yon_char_new(value), &main_config.soft_raw_limit_size, index, array_size_pow);
|
|
|
|
philos_set_pow_size_memory(yon_char_new(value), &main_config.soft_raw_limit_size, index, array_size_pow);
|
|
|
@ -464,6 +465,8 @@ void str_split_value(char* values, int index) {
|
|
|
|
set_size_memory_integer(yon_char_new(value), &main_config.cpu_limit, index);
|
|
|
|
set_size_memory_integer(yon_char_new(value), &main_config.cpu_limit, index);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
get_param_io_limit(arr_values, index_1, size,index, "IOReadBandwidthMax");
|
|
|
|
|
|
|
|
get_param_io_limit(arr_values, index_1, size,index, "IOWriteBandwidthMax");
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|