Commit info for scoop/lib/Scoop:
Modified Files:
Tag: CURRENT
ApacheHandler.pm CGI.pm Subscription.pm Utility.pm
Log Message:
Resyncing CURRENT with all of panner's bugfixes. I swear, independent
development will be happening soon with this. I think I have an excuse.
--j
Index: ApacheHandler.pm
===================================================================
RCS file: /cvs/scoop/scoop/lib/Scoop/ApacheHandler.pm,v
retrieving revision 1.72
retrieving revision 1.72.2.1
diff -r1.72 -r1.72.2.1
51c51
< return $Scoop::MP2 ? &Apache::BAD_GATEWAY : &Apache::Constants::BAD_GATEWAY;
---
> return $Scoop::MP2 ? &Apache::HTTP_SERVICE_UNAVAILABLE : &Apache::Constants::HTTP_SERVICE_UNAVAILABLE;
72c72
<
---
>
318c318
< $S->param->{$k} = $params->{$k};
---
> $S->param->{$k} = $params->{$k} if defined($params->{$k});
Index: CGI.pm
===================================================================
RCS file: /cvs/scoop/scoop/lib/Scoop/CGI.pm,v
retrieving revision 1.7
retrieving revision 1.7.4.1
diff -r1.7 -r1.7.4.1
15c15
<
---
>
22c22
<
---
>
Index: Subscription.pm
===================================================================
RCS file: /cvs/scoop/scoop/lib/Scoop/Subscription.pm,v
retrieving revision 1.15
retrieving revision 1.15.2.1
diff -r1.15 -r1.15.2.1
16,21c16
<
< $S->{UI}->{BLOCKS}->{subscribe_intro_text} ||= qq|
< This is where you should put some introductory information about
< your subscription offerings. Edit (or create) the block "subscribe_intro_text"
< with the text you want here.|;
<
---
>
260c255
< $S->sub_email_manual_change($months, $type);
---
> $S->sub_email_manual_change($months, $type, $S->{UID});
263c258
< $S->sub_email_success($months, $type);
---
> $S->sub_email_success($months, $type, $S->{UID});
279c274
<
---
>
281c276
<
---
>
284c279
<
---
>
309c304
< return 'manual' unless ($S->have_perm("sub_allow_group_change", $user->{perm_group}));
---
> return 'manual' unless ($S->have_perm("suballow_group_change", $user->{perm_group}));
543c538
<
---
>
545,547c540,542
< my $url = $S->{UI}->{VARS}->{site_url}.$S->{UI}->{VARS}->{rootdir}."/user/uid:$S->{UID}";
<
< $message = $S->sub_escape_mail($message, {months=>$months, type=>$type, url=>$url, nick=>$S->{NICK}});
---
> my $url = $S->{UI}->{VARS}->{site_url}.$S->{UI}->{VARS}->{rootdir}."/user/uid:$uid";
>
> $message = $S->sub_escape_mail($message, {months=>$months, type=>$type, url=>$url, nick=>$user->{nickname}});
549c544
<
---
>
553c548
<
---
>
608c603
< return '<p>You are not currently a paid member. Why not <a href="%%rootdir%%/subscribe">become one</a>?</p>' unless ($sub);
---
> return $S->{UI}->{BLOCKS}->{subscribe} unless ($sub);
636d630
<
638,640d631
<
<
<
Index: Utility.pm
===================================================================
RCS file: /cvs/scoop/scoop/lib/Scoop/Utility.pm,v
retrieving revision 1.28
retrieving revision 1.28.2.1
diff -r1.28 -r1.28.2.1
49c49,51
< @files = readdir (UserDir);
---
> while (my $file = readdir (UserDir)) {
> push(@files, $file) if -f "$path/$file";
> }
187,190c189,191
<
< #if (($size > $max_bytes) && ($max_bytes ne 0)) {
< # return( '', '', "Sorry, but you can't upload files larger than <b>$max_bytes</b> bytes");
< #}
---
> if (($max_bytes < $size) && ($max_bytes ne 0)) {
> return("Sorry, but you can't upload files larger than <b>$max_bytes</b> bytes", '', 0, '');
> }
202c203,212
< while (my $line = <$uploadfh>) {
---
> my $cur_size = 0;
> my $chunk;
> # read only as much as the client said it's sending, so that it can't try
> # and trick us into getting a file that's too large
> while ($cur_size < $size) {
> my $remaining = $size - $cur_size;
> my $read_size = ($remaining < 4096) ? $remaining : 4096;
> my $length = read($uploadfh, $chunk, $read_size);
> $cur_size += $length;
>
204c214
< print OUTFH $line;
---
> print OUTFH $chunk;
206c216
< $getfile .= $line;
---
> $getfile .= $chunk;
218d227
<
868,871c877
< #s#([^\x00]|^)($url_regex)(?=[.!?_*=]?[\s\n<()\[\]{}\x01\x02]|$)#$1<a href="$2">$2</a>#gmio;
< # Added (?!>) so that it would look ahead and not linkify urls that have a > in them
< # Whether this will conflict with anything else I don't know YMMV
< s#([^\x00]|^)($url_regex)(?=[.!?_*=](?!>)?[\s\n<()\[\]{}\x01\x02]|$)#$1<a href="$2">$2</a>#gmio;
---
> s#([^\x00]|^)($url_regex)(?=[.!?_*=]?[\s\n<()\[\]{}\x01\x02]|$)#$1<a href="$2">$2</a>#gmio;