generator now executes the user defined system calls at end of file copying