.TH LC_CTX_NEW 3 2020-08-01 "LIBRECAST" "Librecast Programmer's Manual" .SH NAME lc_ctx_new, lc_ctx_free \- create and free Librecast contexts .SH SYNOPSIS .nf .B #include .PP .BI "lc_ctx_t *lc_ctx_new(void);" .BI "void lc_ctx_free(lc_ctx_t " "*ctx" ); .fi .PP Compile and link with \fI\-llibrecast\fP. .SH DESCRIPTION .BR lc_ctx_new () creates a new Librecast context and sets up the environment. Call .BR lc_ctx_free (3) when done. .PP .BR lc_ctx_free () invalidates and frees a Librecast context created with .BR lc_ctx_new (3) . .SH RETURN VALUE .BR lc_ctx_new () returns a pointer to a .I lc_ctx_t handle. On error returns NULL and sets .I errno to .BR ENOMEM . .PP The .BR lc_ctx_free () function returns no value. .SH ERRORS .BR lc_ctx_new () can fail with the following error: .TP .B ENOMEM Out of memory. Possibly, the application hit the .BR RLIMIT_AS or .BR RLIMIT_DATA limit described in .BR getrlimit (2). .SH EXAMPLE .SS Program source \& .EX lc_ctx_t *lctx; lctx = lc_ctx_new(); /* your Librecast program here */ lc_ctx_free(lctx); /* free context when done */ .EE .SH SEE ALSO .BR lc_ctx_free (3)