Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
T
tarantool
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
core
tarantool
Commits
e412879e
Commit
e412879e
authored
2 years ago
by
Georgy Moshkin
Committed by
Dmitry Rodionov
1 year ago
Browse files
Options
Downloads
Patches
Plain Diff
picodata: add support for static stored procedures using ".foo" syntax
parent
fadcdba1
Branches
picodata-25.1
Branches containing commit
No related tags found
1 merge request
!127
move to support only one branch
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/box/module_cache.c
+26
-0
26 additions, 0 deletions
src/box/module_cache.c
with
26 additions
and
0 deletions
src/box/module_cache.c
+
26
−
0
View file @
e412879e
...
...
@@ -380,9 +380,32 @@ module_new(const char *package, size_t package_len,
return
NULL
;
}
struct
module
*
module_current_exe
()
{
struct
module
*
m
=
cache_find
(
NULL
,
0
);
if
(
m
!=
NULL
)
return
m
;
size_t
size
=
sizeof
(
struct
module
)
+
1
;
m
=
malloc
(
size
);
if
(
m
==
NULL
)
{
diag_set
(
OutOfMemory
,
size
,
"malloc"
,
"module"
);
return
NULL
;
}
memset
(
m
,
0
,
size
);
m
->
handle
=
dlopen
(
0
,
RTLD_NOW
);
module_ref
(
m
);
cache_put
(
m
);
return
m
;
}
struct
module
*
module_load_force
(
const
char
*
package
,
size_t
package_len
)
{
if
(
package_len
==
0
)
return
module_current_exe
();
char
path
[
PATH_MAX
];
size_t
size
=
sizeof
(
path
);
...
...
@@ -406,6 +429,9 @@ module_load_force(const char *package, size_t package_len)
struct
module
*
module_load
(
const
char
*
package
,
size_t
package_len
)
{
if
(
package_len
==
0
)
return
module_current_exe
();
char
path
[
PATH_MAX
];
if
(
find_package
(
package
,
package_len
,
path
,
sizeof
(
path
))
!=
0
)
...
...
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