]> granicus.if.org Git - php/commitdiff
fix var usage only when unistd.h available
authorAnatol Belski <ab@php.net>
Mon, 10 Nov 2014 17:21:55 +0000 (18:21 +0100)
committerAnatol Belski <ab@php.net>
Mon, 10 Nov 2014 22:30:14 +0000 (23:30 +0100)
sapi/cli/php_cli_server.c

index 9612352b00e6f110965f39f6f2a62965fe4281eb..49680cede424f837103daf4e8be4ff4c3091a72a 100644 (file)
@@ -259,7 +259,9 @@ static php_cli_server_http_response_status_code_pair template_map[] = {
        { 501, "<h1>%s</h1><p>Request method not supported.</p>" }
 };
 
+#if HAVE_UNISTD_H
 static int php_cli_output_is_tty = OUTPUT_NOT_CHECKED;
+#endif
 
 static size_t php_cli_server_client_send_through(php_cli_server_client *client, const char *str, size_t str_len);
 static php_cli_server_chunk *php_cli_server_chunk_heap_new_self_contained(size_t len);