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
fcc1dfb8
Commit
fcc1dfb8
authored
19 years ago
by
rswindell
Browse files
Options
Downloads
Patches
Plain Diff
Indicate compile date/time, compiler used, and debug-compile in banner message.
Display thread stack limit (if not unlimited).
parent
819f3bb5
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/jsexec.c
+15
-4
15 additions, 4 deletions
src/sbbs3/jsexec.c
with
15 additions
and
4 deletions
src/sbbs3/jsexec.c
+
15
−
4
View file @
fcc1dfb8
...
...
@@ -61,6 +61,7 @@ FILE* errfp;
FILE
*
nulfp
;
FILE
*
statfp
;
char
revision
[
16
];
char
compiler
[
32
];
char
*
host_name
=
NULL
;
char
host_name_buf
[
128
];
BOOL
pause_on_exit
=
FALSE
;
...
...
@@ -75,12 +76,20 @@ BOOL daemonize=FALSE;
void
banner
(
FILE
*
fp
)
{
fprintf
(
fp
,
"
\n
JSexec v%s%c-%s (rev %s) - "
fprintf
(
fp
,
"
\n
JSexec v%s%c-%s (rev %s)
%s
- "
"Execute Synchronet JavaScript Module
\n
"
,
VERSION
,
REVISION
,
PLATFORM_DESC
,
revision
#ifdef _DEBUG
,
" Debug"
#else
,
""
#endif
);
fprintf
(
fp
,
"Compiled %s %s with %s
\n
"
,
__DATE__
,
__TIME__
,
compiler
);
}
void
usage
(
FILE
*
fp
)
...
...
@@ -564,6 +573,10 @@ static BOOL js_init(char** environ)
if
((
js_cx
=
JS_NewContext
(
js_runtime
,
js_cx_stack
))
==
NULL
)
return
(
FALSE
);
if
(
stack_limit
)
fprintf
(
statfp
,
"JavaScript: Thread stack limit: %lu bytes
\n
"
,
stack_limit
);
JS_SetErrorReporter
(
js_cx
,
js_ErrorReporter
);
/* Global Object */
...
...
@@ -596,7 +609,6 @@ long js_exec(const char *fname, char** args)
uint
line_no
;
char
path
[
MAX_PATH
+
1
];
char
line
[
1024
];
char
compiler
[
32
];
char
rev_detail
[
256
];
size_t
len
;
char
*
js_buf
=
NULL
;
...
...
@@ -657,8 +669,6 @@ long js_exec(const char *fname, char** args)
,
STRING_TO_JSVAL
(
JS_NewStringCopyZ
(
js_cx
,
revision
))
,
NULL
,
NULL
,
JSPROP_READONLY
|
JSPROP_ENUMERATE
);
DESCRIBE_COMPILER
(
compiler
);
sprintf
(
rev_detail
,
"JSexec %s%s "
"Compiled %s %s with %s"
,
revision
...
...
@@ -780,6 +790,7 @@ int main(int argc, char **argv, char** environ)
branch
.
auto_terminate
=
TRUE
;
sscanf
(
"$Revision$"
,
"%*s %s"
,
revision
);
DESCRIBE_COMPILER
(
compiler
);
memset
(
&
scfg
,
0
,
sizeof
(
scfg
));
scfg
.
size
=
sizeof
(
scfg
);
...
...
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