From: Andre Noll Date: Tue, 31 Dec 2013 02:15:42 +0000 (+0000) Subject: sched: Mark argument of task_get_notification() as const. X-Git-Tag: v0.5.3~8^2~31 X-Git-Url: http://git.tuebingen.mpg.de/?p=paraslash.git;a=commitdiff_plain;h=0b38d56fdd56cc51ee4286a49a4aa91d83618fc1 sched: Mark argument of task_get_notification() as const. We never write to the memory pointed to by the argument. --- diff --git a/sched.c b/sched.c index 86069029..85f4238b 100644 --- a/sched.c +++ b/sched.c @@ -203,7 +203,7 @@ void task_notify(struct task *t, int err) * * \sa \ref task_notify(). */ -int task_get_notification(struct task *t) +int task_get_notification(const struct task *t) { return t->notification; } diff --git a/sched.h b/sched.h index c706b509..303877a4 100644 --- a/sched.h +++ b/sched.h @@ -80,7 +80,7 @@ int schedule(struct sched *s); char *get_task_list(struct sched *s); void task_notify(struct task *t, int err); void task_notify_all(struct sched *s, int err); -int task_get_notification(struct task *t); +int task_get_notification(const struct task *t); void sched_min_delay(struct sched *s); void sched_request_timeout(struct timeval *to, struct sched *s); void sched_request_timeout_ms(long unsigned ms, struct sched *s);