Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
M
margo
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
19
Issues
19
List
Boards
Labels
Milestones
Merge Requests
2
Merge Requests
2
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
sds
margo
Commits
95bdea25
Commit
95bdea25
authored
Dec 17, 2015
by
Jonathan Jenkins
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add convenience NULL define for margo id
parent
cfd6bf7e
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
3 deletions
+5
-3
include/margo.h
include/margo.h
+2
-0
src/margo.c
src/margo.c
+3
-3
No files found.
include/margo.h
View file @
95bdea25
...
...
@@ -21,6 +21,8 @@ extern "C" {
struct
margo_instance
;
typedef
struct
margo_instance
*
margo_instance_id
;
#define MARGO_INSTANCE_NULL ((margo_instance_id)NULL)
/**
* Initializes margo library from given argobots and Mercury instances.
* @param [in] progress_pool Argobots pool to drive communication
...
...
src/margo.c
View file @
95bdea25
...
...
@@ -54,11 +54,11 @@ margo_instance_id margo_init(ABT_pool progress_pool, ABT_pool handler_pool,
struct
margo_instance
*
mid
;
if
(
handler_mapping_table_size
>=
MAX_HANDLER_MAPPING
)
return
(
NULL
);
return
(
MARGO_INSTANCE_
NULL
);
mid
=
malloc
(
sizeof
(
*
mid
));
if
(
!
mid
)
return
(
NULL
);
return
(
MARGO_INSTANCE_
NULL
);
memset
(
mid
,
0
,
sizeof
(
*
mid
));
mid
->
progress_pool
=
progress_pool
;
...
...
@@ -72,7 +72,7 @@ margo_instance_id margo_init(ABT_pool progress_pool, ABT_pool handler_pool,
{
fprintf
(
stderr
,
"Error: ABT_thread_create()
\n
"
);
free
(
mid
);
return
(
NULL
);
return
(
MARGO_INSTANCE_
NULL
);
}
handler_mapping_table
[
handler_mapping_table_size
].
mid
=
mid
;
...
...
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