Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
P
proview
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Esteban Blanc
proview
Commits
61a8eb84
Commit
61a8eb84
authored
Apr 28, 2004
by
claes
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Priority-handling and check for existing files
parent
cdeb2b17
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
32 additions
and
4 deletions
+32
-4
src/exe/rt_ini/src/ini.c
src/exe/rt_ini/src/ini.c
+30
-3
src/exe/rt_ini/src/rt_ini.c
src/exe/rt_ini/src/rt_ini.c
+2
-1
No files found.
src/exe/rt_ini/src/ini.c
View file @
61a8eb84
...
...
@@ -6,6 +6,8 @@
#elif defined OS_LINUX
# include <sys/wait.h>
# include <sys/types.h>
# include <sys/stat.h>
# include <unistd.h>
#endif
#include "pwr.h"
...
...
@@ -557,6 +559,10 @@ loadSectObject (
if
(
oh
.
cid
==
pwr_eClass_Node
&&
oh
.
oid
.
vid
==
cp
->
node
.
nid
)
cp
->
node
.
nod_oid
=
oh
.
oid
;
/* This is the node object. */
if
(
oh
.
flags
.
b
.
devOnly
)
{
// continue;
}
op
=
ivol_LoadObject
(
sts
,
vp
,
&
oh
,
vol_mLink_load
);
if
(
op
==
NULL
)
{
errh_LogError
(
&
cp
->
log
,
"Loading object %s, %s, parent %s
\n
%m"
,
...
...
@@ -1771,6 +1777,9 @@ ini_ProcInsert (
{
ini_sProc
*
pp
;
char
buf
[
255
];
char
*
s
;
int
ret
;
struct
stat
f_stat
;
pwr_dStatus
(
sts
,
status
,
INI__SUCCESS
);
...
...
@@ -1787,6 +1796,22 @@ ini_ProcInsert (
if
(
file
!=
NULL
&&
file
[
0
]
!=
'\0'
&&
strcmp
(
file
,
"
\"\"
"
))
{
if
(
pp
->
proc
.
file
!=
NULL
)
free
(
pp
->
proc
.
file
);
pp
->
proc
.
file
=
strsav
(
file
);
#if defined(OS_LINUX)
s
=
getenv
(
"pwr_exe"
);
sprintf
(
buf
,
"%s/%s"
,
s
,
file
);
ret
=
stat
(
buf
,
&
f_stat
);
if
(
ret
==
-
1
)
{
s
=
getenv
(
"pwrp_exe"
);
sprintf
(
buf
,
"%s/%s"
,
s
,
file
);
ret
=
stat
(
buf
,
&
f_stat
);
if
(
ret
==
-
1
)
{
pp
->
flags
.
b
.
run
=
0
;
pp
->
proc
.
flags
.
b
.
load
=
0
;
}
}
#endif
}
if
(
arg
!=
NULL
&&
arg
[
0
]
!=
'\0'
&&
strcmp
(
arg
,
"
\"\"
"
))
{
if
(
pp
->
proc
.
arg
!=
NULL
)
free
(
pp
->
proc
.
arg
);
...
...
@@ -1872,8 +1897,10 @@ ini_ProcPrio (
if
(
pp
->
flags
.
b
.
run
)
{
#if defined(OS_LINUX)
if
(
!
(
pp
->
flags
.
b
.
plc
))
{
sprintf
(
set
,
"rt_prio -rp %d %d"
,
pp
->
proc
.
p_prio
,
pp
->
proc
.
pid
);
system
(
set
);
}
#endif
}
}
...
...
src/exe/rt_ini/src/rt_ini.c
View file @
61a8eb84
...
...
@@ -195,6 +195,7 @@ start (
ini_ProcIter
(
&
sts
,
cp
,
proc_mProcess_user
,
ini_ProcLoad
);
ini_ProcIter
(
&
sts
,
cp
,
proc_mProcess_user
,
ini_ProcStart
);
ini_ProcIter
(
&
sts
,
cp
,
proc_mProcess_user
,
ini_ProcPrio
);
qcom_CreateQ
(
&
sts
,
&
cp
->
eventQ
,
NULL
,
"iniEvent"
);
if
(
EVEN
(
sts
))
{
...
...
@@ -451,7 +452,7 @@ terminate (
*/
/* Now sleep for a while */
sleep
(
2
);
sleep
(
3
);
/* Unlink shared memory and semaphores */
...
...
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