Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
H
haskell-igraph
Project
Project
Details
Activity
Releases
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
gargantext
haskell-igraph
Commits
073fd36b
Commit
073fd36b
authored
Jan 21, 2021
by
Kai Zhang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix a bug in c code
parent
2164c9d2
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
5 deletions
+3
-5
bytestring.c
cbits/bytestring.c
+3
-3
haskell_attributes.c
cbits/haskell_attributes.c
+0
-2
No files found.
cbits/bytestring.c
View file @
073fd36b
...
...
@@ -342,7 +342,7 @@ igraph_strvector_t* bsvector_to_strvector(bsvector_t* from) {
igraph_strvector_t
*
str
;
size_t
i
;
igraph_strvector_init
(
str
,
from
->
len
);
for
(
i
=
0
;
i
++
;
i
<
from
->
len
)
{
for
(
i
=
0
;
i
<
from
->
len
;
i
++
)
{
igraph_strvector_set
(
str
,
i
,
bytestring_to_char
(
from
->
data
[
i
]));
}
return
str
;
...
...
@@ -352,8 +352,8 @@ bsvector_t* strvector_to_bsvector(igraph_strvector_t* from) {
bsvector_t
*
str
;
size_t
i
;
bsvector_init
(
str
,
from
->
len
);
for
(
i
=
0
;
i
++
;
i
<
from
->
len
)
{
for
(
i
=
0
;
i
<
from
->
len
;
i
++
)
{
bsvector_set
(
str
,
i
,
char_to_bytestring
(
from
->
data
[
i
]));
}
return
str
;
}
}
\ No newline at end of file
cbits/haskell_attributes.c
View file @
073fd36b
...
...
@@ -466,8 +466,6 @@ int igraph_haskell_attribute_add_edges(igraph_t *graph, const igraph_vector_t *e
}
if
(
oldrec
->
type
==
IGRAPH_ATTRIBUTE_STRING
)
{
if
(
ne
!=
bsvector_size
(
newstr
))
{
printf
(
"number of edges: %d
\n
"
,
ne
);
printf
(
"number of attributes: %d
\n
"
,
bsvector_size
(
newstr
));
IGRAPH_ERROR
(
"Invalid string attribute length"
,
IGRAPH_EINVAL
);
}
IGRAPH_CHECK
(
bsvector_append
(
oldstr
,
newstr
));
...
...
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