fix appendfile problem on macos.
when i open file with mode 'a+' on linux, seek position is 0.
on macos seek position is end of file instead. not documented.
#header#
<title>Mercurial repositories index</title>
</head>
<body>
<h2>Mercurial Repositories</h2>
The specified repository "#repo|escape#" is unknown, sorry.
Please go back to the main repository list page.
#footer#