Waitrud Weber’s blog

things and reminders for memories

html: Analyzer: windows-make:

f:id:Waitrud_Weber:20210214173523p:plain

 

We could limit which the function of Memorization error happened, which is "replace_csv".

 

int main () {

	int ini = initialize_parse ();

	//int a = found_enter_003(".\\SANY0208\.MP4");
	//int a = found_enter_004(".\\001-20210114-004-C-001\.txt");
	//int a = found_enter_006(".\\001-csv-20210210-001\.txt");
	//int b = replace_csv ( csv,  ".\\001-form-20210211-001\.txt");
	//int c = print_csv ();

	int a = checkf_replace ();
	int b = checkf_set_csv ();
	int c = checkf_print_csv (); // OK
	int d = replace_csv ( csv,  ".\\001-form-20210211-001\.txt");
	int e = checkf_print_csv ();

	return 0;
}



int replace_csv (char*** csv, char* form_file ) {
	char str_num[10];
	char* string;
	printf("replace_csv starts.\r\n");

	string = read_all(form_file);

	for( int i =0; i<3; i++ ) {
		for( int j =0; j<3; j++ ) {
			sprintf( str_num, "$%d%d", i, j );
			string = m_replace ( string, str_num, csv[i][j] );
			printf("replace: %d %d |%s|%s|:\r\n|%s|", i, j, str_num, csv[i][j], string);
			sleep(1);
		}
	}

	write_block( ".\\001-html-20210211-001\.txt", string );
	printf("replace_csv ends.\r\n");
	return -1;
}