Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
L
libvncserver
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
rasky
libvncserver
Commits
f57eb874
Commit
f57eb874
authored
Mar 20, 2007
by
runge
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add "Connection: close" to HTTP replies.
parent
61cd498f
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
18 additions
and
2 deletions
+18
-2
ChangeLog
ChangeLog
+3
-0
httpd.c
libvncserver/httpd.c
+15
-2
No files found.
ChangeLog
View file @
f57eb874
2007-03-20 Karl Runge <runge@karlrunge.com>
* libvncserver/httpd.c: Add "Connection: close" to HTTP replies.
2007-03-17 Charles Coffing <cconffing@novell.com>
2007-03-17 Charles Coffing <cconffing@novell.com>
* libvncserver: fix a locking issue
* libvncserver: fix a locking issue
...
...
libvncserver/httpd.c
View file @
f57eb874
...
@@ -59,6 +59,9 @@
...
@@ -59,6 +59,9 @@
#include <tcpd.h>
#include <tcpd.h>
#endif
#endif
#define connection_close
#ifndef connection_close
#define NOT_FOUND_STR "HTTP/1.0 404 Not found\r\n\r\n" \
#define NOT_FOUND_STR "HTTP/1.0 404 Not found\r\n\r\n" \
"<HEAD><TITLE>File Not Found</TITLE></HEAD>\n" \
"<HEAD><TITLE>File Not Found</TITLE></HEAD>\n" \
"<BODY><H1>File Not Found</H1></BODY>\n"
"<BODY><H1>File Not Found</H1></BODY>\n"
...
@@ -67,10 +70,20 @@
...
@@ -67,10 +70,20 @@
"<HEAD><TITLE>Invalid Request</TITLE></HEAD>\n" \
"<HEAD><TITLE>Invalid Request</TITLE></HEAD>\n" \
"<BODY><H1>Invalid request</H1></BODY>\n"
"<BODY><H1>Invalid request</H1></BODY>\n"
#if 1
#define OK_STR "HTTP/1.0 200 OK\r\nContent-Type: text/html\r\n\r\n"
#define OK_STR "HTTP/1.0 200 OK\r\nContent-Type: text/html\r\n\r\n"
#else
#else
#define NOT_FOUND_STR "HTTP/1.0 404 Not found\r\nConnection: close\r\n\r\n" \
"<HEAD><TITLE>File Not Found</TITLE></HEAD>\n" \
"<BODY><H1>File Not Found</H1></BODY>\n"
#define INVALID_REQUEST_STR "HTTP/1.0 400 Invalid Request\r\nConnection: close\r\n\r\n" \
"<HEAD><TITLE>Invalid Request</TITLE></HEAD>\n" \
"<BODY><H1>Invalid request</H1></BODY>\n"
#define OK_STR "HTTP/1.0 200 OK\r\nConnection: close\r\nContent-Type: text/html\r\n\r\n"
#define OK_STR "HTTP/1.0 200 OK\r\nConnection: close\r\nContent-Type: text/html\r\n\r\n"
#endif
#endif
static
void
httpProcessInput
(
rfbScreenInfoPtr
screen
);
static
void
httpProcessInput
(
rfbScreenInfoPtr
screen
);
...
@@ -332,7 +345,7 @@ httpProcessInput(rfbScreenInfoPtr rfbScreen)
...
@@ -332,7 +345,7 @@ httpProcessInput(rfbScreenInfoPtr rfbScreen)
return
;
return
;
}
}
if
(
sscanf
(
buf
,
"GET %s HTTP/1.
0
"
,
fname
)
!=
1
)
{
if
(
sscanf
(
buf
,
"GET %s HTTP/1."
,
fname
)
!=
1
)
{
rfbErr
(
"httpd: couldn't parse GET line
\n
"
);
rfbErr
(
"httpd: couldn't parse GET line
\n
"
);
httpCloseSock
(
rfbScreen
);
httpCloseSock
(
rfbScreen
);
return
;
return
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment