* [gentoo-catalyst] [PATCH] lock: fix hardlink_active definition
@ 2015-10-06 3:48 Mike Frysinger
2015-10-06 6:41 ` Brian Dolbec
0 siblings, 1 reply; 3+ messages in thread
From: Mike Frysinger @ 2015-10-06 3:48 UTC (permalink / raw
To: gentoo-catalyst
This is a member function of a class, so it must have a |self| argument
first. The current code is clearly broken otherwise. Not that it seems
to matter as there aren't any callers in the current codebase.
---
catalyst/lock.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/catalyst/lock.py b/catalyst/lock.py
index a6f9d3a..9f954eb 100644
--- a/catalyst/lock.py
+++ b/catalyst/lock.py
@@ -354,7 +354,7 @@ class LockDir:
return True
return False
- def hardlink_active(lock):
+ def hardlink_active(self, lock):
if not os.path.exists(lock):
return False
--
2.5.2
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [gentoo-catalyst] [PATCH] lock: fix hardlink_active definition
2015-10-06 3:48 [gentoo-catalyst] [PATCH] lock: fix hardlink_active definition Mike Frysinger
@ 2015-10-06 6:41 ` Brian Dolbec
2015-10-06 11:09 ` Anthony G. Basile
0 siblings, 1 reply; 3+ messages in thread
From: Brian Dolbec @ 2015-10-06 6:41 UTC (permalink / raw
To: gentoo-catalyst
On Mon, 5 Oct 2015 23:48:07 -0400
Mike Frysinger <vapier@gentoo.org> wrote:
> This is a member function of a class, so it must have a |self|
> argument first. The current code is clearly broken otherwise. Not
> that it seems to matter as there aren't any callers in the current
> codebase. ---
> catalyst/lock.py | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/catalyst/lock.py b/catalyst/lock.py
> index a6f9d3a..9f954eb 100644
> --- a/catalyst/lock.py
> +++ b/catalyst/lock.py
> @@ -354,7 +354,7 @@ class LockDir:
> return True
> return False
>
> - def hardlink_active(lock):
> + def hardlink_active(self, lock):
> if not os.path.exists(lock):
> return False
>
:)
If you want to re-do all the lock code, go for it. I know Anthony was
looking at putting that on to his TODO list. Maybe the two of you can
get it all in great shape.
--
Brian Dolbec <dolsen>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [gentoo-catalyst] [PATCH] lock: fix hardlink_active definition
2015-10-06 6:41 ` Brian Dolbec
@ 2015-10-06 11:09 ` Anthony G. Basile
0 siblings, 0 replies; 3+ messages in thread
From: Anthony G. Basile @ 2015-10-06 11:09 UTC (permalink / raw
To: gentoo-catalyst
On 10/6/15 2:41 AM, Brian Dolbec wrote:
> On Mon, 5 Oct 2015 23:48:07 -0400
> Mike Frysinger <vapier@gentoo.org> wrote:
>
>> This is a member function of a class, so it must have a |self|
>> argument first. The current code is clearly broken otherwise. Not
>> that it seems to matter as there aren't any callers in the current
>> codebase. ---
>> catalyst/lock.py | 2 +-
>> 1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/catalyst/lock.py b/catalyst/lock.py
>> index a6f9d3a..9f954eb 100644
>> --- a/catalyst/lock.py
>> +++ b/catalyst/lock.py
>> @@ -354,7 +354,7 @@ class LockDir:
>> return True
>> return False
>>
>> - def hardlink_active(lock):
>> + def hardlink_active(self, lock):
>> if not os.path.exists(lock):
>> return False
>>
>
> :)
>
> If you want to re-do all the lock code, go for it. I know Anthony was
> looking at putting that on to his TODO list. Maybe the two of you can
> get it all in great shape.
>
we should write a separate class for file locking with a timeout. the
motivation here is bug #519656. I wrote a sketch of what the class
would do, but I have been more involve with working on GRS and just
haven't gotten to it. also on the TODO list is to get catalyst using
cgroup. catalyst just doesn't die well on TERM or INT. with GRS I use
cgroups and its amazingly clean. one of the best features added to the
kernel in recent history.
--
Anthony G. Basile, Ph.D.
Gentoo Linux Developer [Hardened]
E-Mail : blueness@gentoo.org
GnuPG FP : 1FED FAD9 D82C 52A5 3BAB DC79 9384 FA6E F52D 4BBA
GnuPG ID : F52D4BBA
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2015-10-06 11:09 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-10-06 3:48 [gentoo-catalyst] [PATCH] lock: fix hardlink_active definition Mike Frysinger
2015-10-06 6:41 ` Brian Dolbec
2015-10-06 11:09 ` Anthony G. Basile
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox