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
707216bd
Commit
707216bd
authored
1 year ago
by
Eric Vidal
Browse files
Options
Downloads
Patches
Plain Diff
be sure to use to good value
parent
efa84bee
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/lib66/environ/env_compute.c
+9
-8
9 additions, 8 deletions
src/lib66/environ/env_compute.c
with
9 additions
and
8 deletions
src/lib66/environ/env_compute.c
+
9
−
8
View file @
707216bd
...
...
@@ -24,19 +24,21 @@
#include
<66/service.h>
#include
<66/parse.h>
int
env_compute
(
stralloc
*
result
,
resolve_service_t
*
res
)
{
log_flow
()
;
int
r
;
uint32_t
conf
=
res
->
environ
.
env_overwrite
;
char
*
version
=
res
->
sa
.
s
+
res
->
version
;
char
*
svconf
=
res
->
sa
.
s
+
res
->
environ
.
envdir
;
char
*
name
=
res
->
sa
.
s
+
res
->
name
;
size_t
svconf_len
=
strlen
(
svconf
),
version_len
=
strlen
(
version
)
;
char
src
[
svconf_len
+
1
+
version_len
+
1
]
;
size_t
conflen
=
strlen
(
res
->
sa
.
s
+
res
->
environ
.
envdir
),
versionlen
=
strlen
(
res
->
sa
.
s
+
res
->
version
),
namelen
=
strlen
(
res
->
sa
.
s
+
res
->
name
)
;
char
version
[
versionlen
+
1
]
;
char
svconf
[
conflen
+
1
]
;
char
name
[
namelen
+
1
]
;
char
src
[
conflen
+
1
+
versionlen
+
1
]
;
auto_strings
(
version
,
res
->
sa
.
s
+
res
->
version
)
;
auto_strings
(
svconf
,
res
->
sa
.
s
+
res
->
environ
.
envdir
)
;
auto_strings
(
name
,
res
->
sa
.
s
+
res
->
name
)
;
auto_strings
(
src
,
svconf
,
"/"
,
version
)
;
/** previous version, this is the current version before
...
...
@@ -48,7 +50,6 @@ int env_compute(stralloc *result, resolve_service_t *res)
/** store current configure file version before the switch
* of the symlink with the env_make_symlink() function */
r
=
env_find_current_version
(
&
pversion
,
svconf
)
;
if
(
r
==
-
1
)
log_warnu_return
(
LOG_EXIT_ZERO
,
"find previous configuration file version"
)
;
...
...
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