projects
/
freeside.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
7bb7306
)
export negative byte values to chillispot attributes as 0, RT#5815
author
ivan
<ivan>
Wed, 5 Aug 2009 02:27:08 +0000
(
02:27
+0000)
committer
ivan
<ivan>
Wed, 5 Aug 2009 02:27:08 +0000
(
02:27
+0000)
FS/FS/svc_acct.pm
patch
|
blob
|
history
diff --git
a/FS/FS/svc_acct.pm
b/FS/FS/svc_acct.pm
index
294e327
..
ac97864
100644
(file)
--- a/
FS/FS/svc_acct.pm
+++ b/
FS/FS/svc_acct.pm
@@
-1455,6
+1455,7
@@
sub radius_reply {
my $is = $whatis{$what}.'bytes';
if ( $self->$is() =~ /\d/ ) {
my $big = new Math::BigInt $self->$is();
+ $big = new Math::BigInto '0' if $big->is_neg();
my $att = "Chillispot-Max-\u$what";
$reply{"$att-Octets"} = $big->copy->band(0xffffffff)->bstr;
$reply{"$att-Gigawords"} = $big->copy->brsft(32)->bstr;