Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
Synchronet
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Main
Synchronet
Commits
1538f8ef
Commit
1538f8ef
authored
22 years ago
by
rswindell
Browse files
Options
Downloads
Patches
Plain Diff
Fixed missing semicolon in http_scheme definition.
Fixed bcc build warnings.
parent
d0e18924
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/sbbs3/websrvr.c
+16
-16
16 additions, 16 deletions
src/sbbs3/websrvr.c
with
16 additions
and
16 deletions
src/sbbs3/websrvr.c
+
16
−
16
View file @
1538f8ef
...
...
@@ -46,8 +46,8 @@
static
const
char
*
server_name
=
"Synchronet Web Server"
;
static
const
char
*
newline
=
"
\r\n
"
;
static
const
char
*
http_scheme
=
"http://"
static
const
size_t
http_scheme_len
=
7
;
static
const
char
*
http_scheme
=
"http://"
;
static
const
size_t
http_scheme_len
=
7
;
extern
const
uchar
*
nular
;
...
...
@@ -83,11 +83,11 @@ typedef struct {
char
host
[
128
];
/* The requested host. (virtual hosts) */
int
send_location
;
char
**
cgi_env
;
DWORD
cgi_env_size
;
DWORD
cgi_env_max_size
;
uint
cgi_env_size
;
uint
cgi_env_max_size
;
char
**
cgi_heads
;
DWORD
cgi_heads_size
;
DWORD
cgi_heads_max_size
;
uint
cgi_heads_size
;
uint
cgi_heads_max_size
;
char
cgi_infile
[
128
];
char
cgi_location
[
MAX_REQUEST_LINE
];
char
cgi_status
[
MAX_REQUEST_LINE
];
...
...
@@ -624,11 +624,11 @@ static int close_socket(SOCKET sock)
static
void
close_request
(
http_session_t
*
session
)
{
int
i
;
u
int
i
;
if
(
session
->
req
.
cgi_heads_size
)
{
for
(
i
=
0
;
session
->
req
.
cgi_heads_size
>
i
;
i
++
)
for
(
i
=
0
;
i
<
session
->
req
.
cgi_heads_size
;
i
++
)
FREE_AND_NULL
(
session
->
req
.
cgi_heads
[
i
]);
FREE_AND_NULL
(
session
->
req
.
cgi_heads
);
session
->
req
.
cgi_heads_size
=
0
;
...
...
@@ -650,7 +650,7 @@ static void close_request(http_session_t * session)
static
int
get_header_type
(
char
*
header
)
{
int
i
;
int
i
;
for
(
i
=
0
;
headers
[
i
].
text
!=
NULL
;
i
++
)
{
if
(
!
stricmp
(
header
,
headers
[
i
].
text
))
{
return
(
headers
[
i
].
id
);
...
...
@@ -661,7 +661,7 @@ static int get_header_type(char *header)
static
char
*
get_header
(
int
id
)
{
int
i
;
int
i
;
for
(
i
=
0
;
headers
[
i
].
text
!=
NULL
;
i
++
)
{
if
(
headers
[
i
].
id
==
id
)
{
...
...
@@ -1050,7 +1050,7 @@ static BOOL parse_headers(http_session_t * session)
}
}
sprintf
(
session
->
req
.
cgi_infile
,
"%s/SBBS_CGI.%d"
,
startup
->
cgi_temp_dir
,
session
->
socket
);
if
((
incgi
=
open
(
session
->
req
.
cgi_infile
,
O_WRONLY
|
O_CREAT
|
O_TRUNC
,
S_IR
USR
|
S_IW
USR
))
>
0
)
{
if
((
incgi
=
open
(
session
->
req
.
cgi_infile
,
O_WRONLY
|
O_CREAT
|
O_TRUNC
,
S_IR
EAD
|
S_IW
RITE
))
>
0
)
{
lprintf
(
"%04d Created %s"
,
session
->
socket
,
session
->
req
.
cgi_infile
);
if
(
content_len
)
{
recvfilesocket
(
session
->
socket
,
incgi
,
NULL
,
content_len
);
...
...
@@ -1320,7 +1320,7 @@ static BOOL parse_cgi_headers(http_session_t *session,FILE *output) {
}
static
void
send_cgi_response
(
http_session_t
*
session
,
FILE
*
output
)
{
int
i
;
u
int
i
;
long
filepos
;
struct
stat
stats
;
time_t
ti
;
...
...
@@ -1363,7 +1363,7 @@ static void send_cgi_response(http_session_t *session,FILE *output) {
sendsocket
(
session
->
socket
,
newline
,
2
);
}
for
(
i
=
0
;
session
->
req
.
cgi_heads_size
>
i
;
i
++
)
for
(
i
=
0
;
i
<
session
->
req
.
cgi_heads_size
;
i
++
)
FREE_AND_NULL
(
session
->
req
.
cgi_heads
[
i
]);
FREE_AND_NULL
(
session
->
req
.
cgi_heads
);
session
->
req
.
cgi_heads_size
=
0
;
...
...
@@ -1373,13 +1373,13 @@ static void send_cgi_response(http_session_t *session,FILE *output) {
static
BOOL
exec_cgi
(
http_session_t
*
session
)
{
int
status
;
char
cmdline
[
MAX_PATH
+
256
];
char
*
args
[
4
];
int
i
;
char
*
comspec
;
FILE
*
output
;
#ifdef __unix__
int
i
;
int
status
;
FILE
*
output
;
pid_t
child
;
#endif
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment