@@ -100,9 +100,7 @@ pub trait EvalContextExt<'tcx>: crate::MiriInterpCxExt<'tcx> {
100100 let buf = this. read_pointer ( buf) ?;
101101 let count = this. read_target_usize ( n) ?;
102102 trace ! ( "Called write({:?}, {:?}, {:?})" , fd, buf, count) ;
103- let result = this. write ( fd, buf, count, None ) ?;
104- // Now, `result` is the value we return back to the program.
105- this. write_scalar ( result, dest) ?;
103+ this. write ( fd, buf, count, None , dest) ?;
106104 }
107105 "pread" => {
108106 let [ fd, buf, count, offset] = this. check_shim ( abi, Abi :: C { unwind : false } , link_name, args) ?;
@@ -119,9 +117,7 @@ pub trait EvalContextExt<'tcx>: crate::MiriInterpCxExt<'tcx> {
119117 let count = this. read_target_usize ( n) ?;
120118 let offset = this. read_scalar ( offset) ?. to_int ( this. libc_ty_layout ( "off_t" ) . size ) ?;
121119 trace ! ( "Called pwrite({:?}, {:?}, {:?}, {:?})" , fd, buf, count, offset) ;
122- let result = this. write ( fd, buf, count, Some ( offset) ) ?;
123- // Now, `result` is the value we return back to the program.
124- this. write_scalar ( result, dest) ?;
120+ this. write ( fd, buf, count, Some ( offset) , dest) ?;
125121 }
126122 "pread64" => {
127123 let [ fd, buf, count, offset] = this. check_shim ( abi, Abi :: C { unwind : false } , link_name, args) ?;
@@ -138,9 +134,7 @@ pub trait EvalContextExt<'tcx>: crate::MiriInterpCxExt<'tcx> {
138134 let count = this. read_target_usize ( n) ?;
139135 let offset = this. read_scalar ( offset) ?. to_int ( this. libc_ty_layout ( "off64_t" ) . size ) ?;
140136 trace ! ( "Called pwrite64({:?}, {:?}, {:?}, {:?})" , fd, buf, count, offset) ;
141- let result = this. write ( fd, buf, count, Some ( offset) ) ?;
142- // Now, `result` is the value we return back to the program.
143- this. write_scalar ( result, dest) ?;
137+ this. write ( fd, buf, count, Some ( offset) , dest) ?;
144138 }
145139 "close" => {
146140 let [ fd] = this. check_shim ( abi, Abi :: C { unwind : false } , link_name, args) ?;
0 commit comments