소스 검색

Fixed bug in handle_directory_request, that used the unintialized path variable instead of dir for an error message.

Colin Leitner 14 년 전
부모
커밋
22754f403d
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      mongoose.c

+ 1 - 1
mongoose.c

@@ -2403,7 +2403,7 @@ static void handle_directory_request(struct mg_connection *conn,
 
 
   if ((dirp = opendir(dir)) == NULL) {
   if ((dirp = opendir(dir)) == NULL) {
     send_http_error(conn, 500, "Cannot open directory",
     send_http_error(conn, 500, "Cannot open directory",
-        "Error: opendir(%s): %s", path, strerror(ERRNO));
+        "Error: opendir(%s): %s", dir, strerror(ERRNO));
     return;
     return;
   }
   }