<i>fcopy and encoding errors: no partial write, no transparency write</i> status still Open with 4 other changes
by
.
D 2023-11-17T08:02:51.535
J icomment Hi\sJan,\r\n\r\nthank\syou\sfor\sthe\sgood\sthoughts.\r\n\r\nEven\sif\sthere\sis\sdata\sloss\spossible\son\sthe\s3rd\scase,\sI\swould\sjust\saccept\sthat\sdata\sloss.\r\n\r\nThe\sfcopy\slogically\sas:\r\n\r\n<verbatim>\r\nif\s{[catch\s{read\s$rf}\sdata]}\s{\r\n\s\s\s\s#\sread\serror\shandling\r\n}\selseif\s{[catch\s{puts\s-nonewline\s$wf\s$data}\serr]}\s{\r\n\s\s\s\s#\swrite\sdata\serror\r\n}\s\s\r\n</verbatim>\r\n\r\nCurrently,\sif\swe\sloose\sdata\son\sthe\sputs,\sit\sis\slost\s-\spoint.\r\n\r\nSo,\sI\swould\sgo\sto\sdocument\sfor\sfcopy\son\sencoding\serrors:\r\n\r\n\s\s\s*\s\s\sOn\sread\sencoding\serrors,\sthe\sdata\sbefore\sthe\serror\sis\swritten.\sThe\scurrent\sread\sfile\spointer\sis\son\sthe\serror\sposition.\sA\srecovery\sis\spossible\sby\sfixing\sthe\sissue\sand\scontinue\slike:\r\n\r\n<verbatim>\r\nfconfigure\s$rf\s-encoding\sbinary\r\nfcopy\s$rf\s$wf\r\n</verbatim>\r\n\r\n\s\s\s*\s\s\sOn\swrite\sencoding\serrors,\sthe\sdata\sbefore\sthe\swrite\serror\sis\swritten.\sThe\sdata\scausing\sthe\serror\sand\seventual\sfollowing\sdata\sis\slost.\r\n\r\nIs\sthere\sa\sway,\sthat\sa\sscript\smay\smake\sthe\sdifference\sbetween\sread\sand\swrite\sencoding\serror?\r\nBoth\swill\sthrow\s"EILSEQ"\serror\sand\shave\sthe\ssame\serror\smessage.\r\n\r\nThank\syou\sand\stake\scare,\r\nHarald
J login oehhar
J mimetype text/x-fossil-wiki
J username oehhar
K a173f9229fe2fec80dc8d43a16c1d7366fb11945
U oehhar
Z e886c11fc33f980f0274f0b06aed6744