Index: filed.c ================================================================== --- filed.c +++ filed.c @@ -680,10 +680,13 @@ buffer_st->method = FILED_REQUEST_METHOD_HEAD; } /* Note path */ strcpy(buffer_st->path, path); + + /* Reset buffer for later use */ + buffer = buffer_st->tmpbuf; for (i = 0; i < 100; i++) { fgets_ret = fgets(buffer, buffer_len, fp); if (fgets_ret == NULL) { break;