summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--philo.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/philo.go b/philo.go
index 19e555a..c849add 100644
--- a/philo.go
+++ b/philo.go
@@ -54,13 +54,13 @@ func hungry(p *Philo) stateFn {
return eat
case <-time.After(time.Second):
p.LHS <- true // put left fork back
- return starving
+ return starve
}
return eat
}
-func starving(p *Philo) stateFn {
+func starve(p *Philo) stateFn {
p.state("is starving")
rndDelay()