Minor audit of new top-level state machine

Also, give Jonas copyright for his contribution to Finit.

Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
This commit is contained in:
Joachim Nilsson committed 2016-06-07 18:32:31 +02:00
1 parent 79b95daf3a
commit 4a8a92af2e
2 files changed
+8 -2

No files matched your search

+7 -1
View File
@@ -1,6 +1,6 @@
/* Finit state machine /* Finit state machine
* *
* Copyright (c) 2016 xxx * Copyright (c) 2016 Jonas Johansson <jonas.johansson@westermo.se>
* *
* Permission is hereby granted, free of charge, to any person obtaining a copy * Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal * of this software and associated documentation files (the "Software"), to deal
@@ -50,16 +50,22 @@ static char *sm_status(sm_t *sm)
switch (sm->state) { switch (sm->state) {
case SM_BOOTSTRAP_STATE: case SM_BOOTSTRAP_STATE:
return "bootstrap"; return "bootstrap";
case SM_RUNNING_STATE: case SM_RUNNING_STATE:
return "running"; return "running";
case SM_RUNLEVEL_CHANGE_STATE: case SM_RUNLEVEL_CHANGE_STATE:
return "runlevel/change"; return "runlevel/change";
case SM_RUNLEVEL_WAIT_STATE: case SM_RUNLEVEL_WAIT_STATE:
return "runlevel/wait"; return "runlevel/wait";
case SM_RELOAD_CHANGE_STATE: case SM_RELOAD_CHANGE_STATE:
return "reload/change"; return "reload/change";
case SM_RELOAD_WAIT_STATE: case SM_RELOAD_WAIT_STATE:
return "reload/wait"; return "reload/wait";
default: default:
return "unknown"; return "unknown";
} }
+1 -1
View File
@@ -1,6 +1,6 @@
/* Finit state machine /* Finit state machine
* *
* Copyright (c) 2016 xxx * Copyright (c) 2016 Jonas Johansson <jonas.johansson@westermo.se>
* *
* Permission is hereby granted, free of charge, to any person obtaining a copy * Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal * of this software and associated documentation files (the "Software"), to deal