Commit graph

11 commits

Author SHA1 Message Date
cinap_lenrek ac88ce4f7f make bind(2) error handling consistent
The mount() and bind() syscalls return -1 on error,
and the mountid sequence number on success.

The manpage states that the mountid sequence number
is a positive integer, but the kernels implementation
currently uses a unsigned 32-bit integer and does not
guarantee that the mountid will not become negative.

Most code just cares about the error, so test for
the -1 error value only.
2020-05-02 17:32:01 +02:00
mischief 6fa3e08412 cfs: close mount half of pipe, fixes cfs not exiting when unmounted 2018-09-19 13:27:55 -07:00
cinap_lenrek df6c190831 cfs: fix cfsctl interaction with mount cache (mount -C flag)
the root fileserver is mounted with the mount cache enabled
causing the contents of the cfsctl file to be cached as well
leading to wrong results. so after we generated the new stat
buffer, we increment the qid.vers so the cache starts out
clean.
2017-01-06 02:54:26 +01:00
cinap_lenrek a0d4c5e208 make error handling in 9p service loops consistent
when we get eof, stop the loop immidiately and do not
rely on the read to eventually return an error.

when convM2S() fails to decode the message, error out
and stop the loop. there is no point in continuing.
2016-07-24 02:21:32 +02:00
cinap_lenrek 772afbe98c format pointer subtraction results with %zd instead of %ld (for long -> intptr on amd64) 2016-01-07 04:44:13 +01:00
cinap_lenrek 651fa5bd50 cfs: change default mountpoint to /mnt/cfs and fix the manual (thanks mischief) 2014-12-11 20:38:04 +01:00
cinap_lenrek 840ade48c4 fix syslog() use with linefeeds for various programs 2014-10-29 17:29:09 +01:00
cinap_lenrek e36d9f5c4e make filesystem handling of read9pmsg() consistent 2013-06-16 06:26:31 +02:00
cinap_lenrek 70223416cd cfs: fix bad memory deref in rstat (from yk's patch/cfs-rstatctlbug) 2012-02-11 13:25:23 +01:00
Taru Karttunen a9060cc06b Import sources from 2011-03-30 iso image - lib 2011-03-30 19:35:09 +03:00
Taru Karttunen e5888a1ffd Import sources from 2011-03-30 iso image 2011-03-30 15:46:40 +03:00