Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
L
lxc
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Chen Yisong
lxc
Commits
4f6b5266
Unverified
Commit
4f6b5266
authored
Jul 20, 2020
by
Christian Brauner
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
lxclock: hide unnecessary symbols
Signed-off-by:
Christian Brauner
<
christian.brauner@ubuntu.com
>
parent
7cf9ab57
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
22 additions
and
11 deletions
+22
-11
compiler.h
src/lxc/compiler.h
+4
-0
lxclock.h
src/lxc/lxclock.h
+12
-10
Makefile.am
src/tests/Makefile.am
+6
-1
No files found.
src/lxc/compiler.h
View file @
4f6b5266
...
...
@@ -79,4 +79,8 @@
#define __hidden __attribute__((visibility("hidden")))
#endif
#ifndef __public
#define __public __attribute__((visibility("default")))
#endif
#endif
/* __LXC_COMPILER_H */
src/lxc/lxclock.h
View file @
4f6b5266
...
...
@@ -11,6 +11,8 @@
#include <time.h>
#include <unistd.h>
#include "compiler.h"
#ifndef F_OFD_GETLK
#define F_OFD_GETLK 36
#endif
...
...
@@ -71,7 +73,7 @@ struct lxc_lock {
* freed when the container is freed), and \c u.f.fd = -1.
*
*/
extern
struct
lxc_lock
*
lxc_newlock
(
const
char
*
lxcpath
,
const
char
*
name
);
__hidden
extern
struct
lxc_lock
*
lxc_newlock
(
const
char
*
lxcpath
,
const
char
*
name
);
/*!
* \brief Take an existing lock.
...
...
@@ -89,7 +91,7 @@ extern struct lxc_lock *lxc_newlock(const char *lxcpath, const char *name);
* (except in the test case) I may remove the support for it in sem as
* well.
*/
extern
int
lxclock
(
struct
lxc_lock
*
lock
,
int
timeout
);
__hidden
extern
int
lxclock
(
struct
lxc_lock
*
lock
,
int
timeout
);
/*!
* \brief Unlock specified lock previously locked using \ref lxclock().
...
...
@@ -99,24 +101,24 @@ extern int lxclock(struct lxc_lock *lock, int timeout);
* \return \c 0 on success, \c -2 if provided lock was not already held,
* otherwise \c -1 with \c errno saved from \c fcntl(2) or sem_post function.
*/
extern
int
lxcunlock
(
struct
lxc_lock
*
lock
);
__hidden
extern
int
lxcunlock
(
struct
lxc_lock
*
lock
);
/*!
* \brief Free a lock created by \ref lxc_newlock().
*
* \param lock Lock.
*/
extern
void
lxc_putlock
(
struct
lxc_lock
*
lock
);
__hidden
extern
void
lxc_putlock
(
struct
lxc_lock
*
lock
);
/*!
* \brief Lock the current process.
*/
extern
void
process_lock
(
void
);
__hidden
extern
void
process_lock
(
void
);
/*!
* \brief Unlock the current process.
*/
extern
void
process_unlock
(
void
);
__hidden
extern
void
process_unlock
(
void
);
struct
lxc_container
;
...
...
@@ -127,14 +129,14 @@ struct lxc_container;
*
* \return As for \ref lxclock().
*/
extern
int
container_mem_lock
(
struct
lxc_container
*
c
);
__hidden
extern
int
container_mem_lock
(
struct
lxc_container
*
c
);
/*!
* \brief Unlock the containers memory.
*
* \param c Container.
*/
extern
void
container_mem_unlock
(
struct
lxc_container
*
c
);
__hidden
extern
void
container_mem_unlock
(
struct
lxc_container
*
c
);
/*!
* \brief Lock the containers disk data.
...
...
@@ -144,7 +146,7 @@ extern void container_mem_unlock(struct lxc_container *c);
* \return \c 0 on success, or an \ref lxclock() error return
* values on error.
*/
extern
int
container_disk_lock
(
struct
lxc_container
*
c
);
__hidden
extern
int
container_disk_lock
(
struct
lxc_container
*
c
);
/*!
* \brief Unlock the containers disk data.
...
...
@@ -152,6 +154,6 @@ extern int container_disk_lock(struct lxc_container *c);
* \param c Container.
*
*/
extern
void
container_disk_unlock
(
struct
lxc_container
*
c
);
__hidden
extern
void
container_disk_unlock
(
struct
lxc_container
*
c
);
#endif
src/tests/Makefile.am
View file @
4f6b5266
...
...
@@ -74,7 +74,12 @@ lxc_test_device_add_remove_SOURCES = device_add_remove.c
lxc_test_getkeys_SOURCES
=
getkeys.c
lxc_test_get_item_SOURCES
=
get_item.c
lxc_test_list_SOURCES
=
list.c
lxc_test_locktests_SOURCES
=
locktests.c
lxc_test_locktests_SOURCES
=
locktests.c
\
../lxc/caps.c ../lxc/caps.h
\
../lxc/file_utils.c ../lxc/file_utils.h
\
../lxc/log.c ../lxc/log.h
\
../lxc/lxclock.c ../lxc/lxclock.h
\
../lxc/string_utils.c ../lxc/string_utils.h
lxc_test_lxcpath_SOURCES
=
lxcpath.c
lxc_test_may_control_SOURCES
=
may_control.c
lxc_test_mount_injection_SOURCES
=
mount_injection.c
\
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment