--- lbbs/src/screen.c 2025/06/08 09:25:25 1.89 +++ lbbs/src/screen.c 2025/06/09 15:39:30 1.90 @@ -426,32 +426,26 @@ int display_data(const void *p_data, lon break; case KEY_F2: // For test only EDITOR_DATA *p_editor_data; - size_t data_new_len = strlen(p_data) + 1; + // size_t data_new_len = strlen(p_data) + LINE_BUFFER_LEN; - char *p_data_new = malloc(data_new_len); - if (p_data_new == NULL) - { - break; - } + // char *p_data_new = malloc(data_new_len); + // if (p_data_new == NULL) + // { + // break; + // } p_editor_data = editor_data_load(p_data); if (p_editor_data == NULL) { - free(p_data_new); + // free(p_data_new); break; } editor_display(p_editor_data); - editor_data_save(p_editor_data, p_data_new, data_new_len); - - if (strcmp(p_data, p_data_new) != 0) - { - log_error("Data was changed\n"); - } - + // editor_data_save(p_editor_data, p_data_new, data_new_len); editor_data_cleanup(p_editor_data); p_editor_data = NULL; - free(p_data_new); - p_data_new = NULL; + // free(p_data_new); + // p_data_new = NULL; // Refresh after display editor line_current -= (screen_current_line - screen_begin_line);