Like in libc.
(String s, int len, RandomAccessFile f)
| 197 | |
| 198 | /** Like in libc. */ |
| 199 | public static void fwriteString(String s, int len, RandomAccessFile f) throws IOException { |
| 200 | if (s == null) |
| 201 | return; |
| 202 | int diff = len - s.length(); |
| 203 | if (diff > 0) { |
| 204 | f.write(stringToBytes(s)); |
| 205 | |
| 206 | f.write(nullfiller, 0, diff); |
| 207 | } |
| 208 | else |
| 209 | f.write(stringToBytes(s), 0, len); |
| 210 | } |
| 211 | |
| 212 | /** Like in libc */ |
| 213 | public static RandomAccessFile fopen(String name, String mode) { |
nothing calls this directly
no test coverage detected