Add missing statics, and remove the 'tildefriends check' command.

git-svn-id: https://www.unprompted.com/svn/projects/tildefriends/trunk@4838 ed5197a5-7fde-0310-b194-c3ffbd925b24
This commit is contained in:
2024-02-10 16:50:00 +00:00
parent 51a327c52d
commit 6c5a7b0751
17 changed files with 93 additions and 304 deletions

View File

@ -17,14 +17,10 @@ typedef struct _tf_tls_context_t {
JSValue object;
} tf_tls_context_t;
static JSValue _tls_context_set_certificate(JSContext* context, JSValueConst this_val, int argc, JSValueConst* argv);
static JSValue _tls_context_set_private_key(JSContext* context, JSValueConst this_val, int argc, JSValueConst* argv);
static JSValue _tls_context_add_trusted_certificate(JSContext* context, JSValueConst this_val, int argc, JSValueConst* argv);
static JSValue _tls_context_create(JSContext* context, JSValueConst this_val, int argc, JSValueConst* argv);
static void _tls_context_finalizer(JSRuntime *runtime, JSValue value);
JSValue _tls_context_set_certificate(JSContext* context, JSValueConst this_val, int argc, JSValueConst* argv)
static JSValue _tls_context_set_certificate(JSContext* context, JSValueConst this_val, int argc, JSValueConst* argv)
{
tf_tls_context_t* tls = JS_GetOpaque(this_val, _classId);
const char* value = JS_ToCString(context, argv[0]);
@ -33,7 +29,7 @@ JSValue _tls_context_set_certificate(JSContext* context, JSValueConst this_val,
return JS_UNDEFINED;
}
JSValue _tls_context_set_private_key(JSContext* context, JSValueConst this_val, int argc, JSValueConst* argv)
static JSValue _tls_context_set_private_key(JSContext* context, JSValueConst this_val, int argc, JSValueConst* argv)
{
tf_tls_context_t* tls = JS_GetOpaque(this_val, _classId);
const char* value = JS_ToCString(context, argv[0]);
@ -42,7 +38,7 @@ JSValue _tls_context_set_private_key(JSContext* context, JSValueConst this_val,
return JS_UNDEFINED;
}
JSValue _tls_context_add_trusted_certificate(JSContext* context, JSValueConst this_val, int argc, JSValueConst* argv)
static JSValue _tls_context_add_trusted_certificate(JSContext* context, JSValueConst this_val, int argc, JSValueConst* argv)
{
tf_tls_context_t* tls = JS_GetOpaque(this_val, _classId);
const char* value = JS_ToCString(context, argv[0]);
@ -77,7 +73,7 @@ int tf_tls_context_get_count()
return _count;
}
JSValue _tls_context_create(JSContext* context, JSValueConst this_val, int argc, JSValueConst* argv)
static JSValue _tls_context_create(JSContext* context, JSValueConst this_val, int argc, JSValueConst* argv)
{
tf_tls_context_t* tls = tf_malloc(sizeof(tf_tls_context_t));
memset(tls, 0, sizeof(*tls));
@ -96,7 +92,7 @@ JSValue _tls_context_create(JSContext* context, JSValueConst this_val, int argc,
return tls->object;
}
void _tls_context_finalizer(JSRuntime *runtime, JSValue value)
static void _tls_context_finalizer(JSRuntime *runtime, JSValue value)
{
tf_tls_context_t* tls = JS_GetOpaque(value, _classId);
if (tls->context)