linux-hotplug.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] Some function locals in udev_rules_parse.c were needlessly
@ 2008-08-31 17:30 Alan Jenkins
  2008-09-01 14:32 ` [PATCH] Some function locals in udev_rules_parse.c were needlessly declared as static Kay Sievers
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Alan Jenkins @ 2008-08-31 17:30 UTC (permalink / raw)
  To: linux-hotplug

This does not affect current behaviour.  However, it is required to
make the functions thread-safe.  (I'm playing with a threaded udevd).

Signed-off-by: Alan Jenkins <alan-jenkins@tuffmail.co.uk>

diff --git a/udev/udev_rules_parse.c b/udev/udev_rules_parse.c
index 705b3fe..90b139b 100644
--- a/udev/udev_rules_parse.c
+++ b/udev/udev_rules_parse.c
@@ -41,7 +41,7 @@ void udev_rules_iter_init(struct udev_rules *rules)
 
 struct udev_rule *udev_rules_iter_next(struct udev_rules *rules)
 {
-	static struct udev_rule *rule;
+	struct udev_rule *rule;
 
 	if (!rules)
 		return NULL;
@@ -61,7 +61,7 @@ struct udev_rule *udev_rules_iter_next(struct udev_rules *rules)
 
 struct udev_rule *udev_rules_iter_label(struct udev_rules *rules, const char *label)
 {
-	static struct udev_rule *rule;
+	struct udev_rule *rule;
 	size_t start = rules->current;
 
 next:



^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2008-09-01 17:50 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-08-31 17:30 [PATCH] Some function locals in udev_rules_parse.c were needlessly Alan Jenkins
2008-09-01 14:32 ` [PATCH] Some function locals in udev_rules_parse.c were needlessly declared as static Kay Sievers
2008-09-01 17:37 ` [PATCH] Some function locals in udev_rules_parse.c were needlessly Alan Jenkins
2008-09-01 17:50 ` [PATCH] Some function locals in udev_rules_parse.c were Kay Sievers

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).