Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
6
66
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
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
Eric Vidal
66
Commits
13bb05f1
Commit
13bb05f1
authored
6 years ago
by
Eric Vidal
Browse files
Options
Downloads
Patches
Plain Diff
remove graph_rdepends func
parent
8be0fb46
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/include/66/graph.h
+0
-2
0 additions, 2 deletions
src/include/66/graph.h
src/lib66/graph.c
+0
-71
0 additions, 71 deletions
src/lib66/graph.c
with
0 additions
and
73 deletions
src/include/66/graph.h
+
0
−
2
View file @
13bb05f1
...
...
@@ -93,8 +93,6 @@ extern int graph_type_src(genalloc *ga,char const *tree,unsigned int what) ;
extern
int
graph_build
(
graph_t
*
g
,
stralloc
*
sagraph
,
genalloc
*
tokeep
,
char
const
*
tree
)
;
extern
int
graph_rdepends
(
genalloc
*
ga
,
graph_t
*
g
,
char
const
*
name
,
char
const
*
src
)
;
extern
int
graph_master
(
genalloc
*
ga
,
graph_t
*
g
)
;
extern
int
graph_sort
(
graph_t
*
g
)
;
...
...
This diff is collapsed.
Click to expand it.
src/lib66/graph.c
+
0
−
71
View file @
13bb05f1
...
...
@@ -278,77 +278,6 @@ int graph_master(genalloc *ga, graph_t *g)
return
1
;
}
int
graph_rdepends
(
genalloc
*
ga
,
graph_t
*
g
,
char
const
*
name
,
char
const
*
src
)
{
unsigned
int
i
,
k
;
int
r
;
char
*
string
=
g
->
string
;
unsigned
int
type
=
graph_search
(
g
,
name
)
;
/** bundle , we need to check every service set onto it*/
if
(
genalloc_s
(
vertex_graph_t
,
&
g
->
vertex
)[
type
].
type
==
BUNDLE
)
{
for
(
k
=
0
;
k
<
genalloc_s
(
vertex_graph_t
,
&
g
->
vertex
)[
type
].
ndeps
;
k
++
)
{
char
*
depname
=
g
->
string
+
genalloc_s
(
vertex_graph_t
,
&
genalloc_s
(
vertex_graph_t
,
&
g
->
vertex
)[
type
].
dps
)[
k
].
name
;
if
(
!
stra_cmp
(
ga
,
depname
))
{
if
(
!
stra_add
(
ga
,
depname
))
{
VERBO3
strerr_warnwu3x
(
"add: "
,
depname
,
" as dependency to remove"
)
;
return
0
;
}
}
r
=
graph_rdepends
(
ga
,
g
,
depname
,
src
)
;
if
(
!
r
)
{
VERBO3
strerr_warnwu2x
(
"find services depending on: "
,
name
)
;
return
0
;
}
if
(
r
==
2
)
{
VERBO3
strerr_warnt2x
(
"any services don't depends on: "
,
name
)
;
return
2
;
}
}
}
for
(
i
=
0
;
i
<
g
->
nvertex
;
i
++
)
{
char
*
master
=
string
+
genalloc_s
(
vertex_graph_t
,
&
g
->
vertex
)[
i
].
name
;
if
(
obstr_equal
(
name
,
master
))
continue
;
if
(
genalloc_s
(
vertex_graph_t
,
&
g
->
vertex
)[
i
].
ndeps
)
{
for
(
k
=
0
;
k
<
genalloc_s
(
vertex_graph_t
,
&
g
->
vertex
)[
i
].
ndeps
;
k
++
)
{
char
*
depname
=
string
+
genalloc_s
(
vertex_graph_t
,
&
genalloc_s
(
vertex_graph_t
,
&
g
->
vertex
)[
i
].
dps
)[
k
].
name
;
if
(
obstr_equal
(
name
,
depname
))
{
if
(
!
stra_cmp
(
ga
,
master
))
{
if
(
!
stra_add
(
ga
,
master
))
{
VERBO3
strerr_warnwu3x
(
"add: "
,
depname
,
" as dependency to remove"
)
;
return
0
;
}
r
=
graph_rdepends
(
ga
,
g
,
master
,
src
)
;
if
(
!
r
)
return
0
;
}
}
}
}
}
if
(
!
genalloc_len
(
stralist
,
ga
))
return
2
;
//genalloc_reverse(stralist,ga) ;
return
1
;
}
/** what = 0 -> only classic
* what = 1 -> only atomic
* what = 2 -> both
...
...
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