Replace CArray by CPointer (#406)

Also do some cleanup.
This commit is contained in:
SvyatoslavScherbina
2017-03-28 17:44:08 +03:00
committed by Nikolay Igotti
parent e36b5d3476
commit c1d9dc1cbb
17 changed files with 176 additions and 143 deletions
+2 -2
View File
@@ -35,14 +35,14 @@ fun main(args: Array<String>) {
.ensureUnixCallResult { it >= 0 }
while (true) {
val length = read(commFd, buffer.ptr, bufferLength)
val length = read(commFd, buffer, bufferLength)
.ensureUnixCallResult { it >= 0 }
if (length == 0L) {
break
}
write(commFd, buffer.ptr, length)
write(commFd, buffer, length)
.ensureUnixCallResult { it >= 0 }
}
}