[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

CVS Update: gleipnir



Log Message:
-----------
Correctly armor $ingroups

Modified Files:
--------------
    gleipnir/public_html/gallery:
        index.pl

Revision Data
-------------
Index: index.pl
===================================================================
RCS file: /cvs/gleipnir/public_html/gallery/index.pl,v
retrieving revision 1.2
retrieving revision 1.3
diff -Lpublic_html/gallery/index.pl -Lpublic_html/gallery/index.pl -u -r1.2 -r1.3
--- public_html/gallery/index.pl
+++ public_html/gallery/index.pl
@@ -86,7 +86,7 @@
   $ingroups = " gid is null " . $ingroups;
 
 	my $SQL = <<EOT;
-select identifier, galleryid from gallery where $ingroups
+select identifier, galleryid from gallery where ($ingroups)
 EOT
 	
 	my $cursor = $dbh->prepare($SQL);
@@ -153,7 +153,7 @@
 
 	my $SQL = <<EOT;
 select gp.pictureid, gp.caption, gp.thumb_path from gallery_picture gp left join gallery g on g.galleryid = gp.gallery
-where $ingroups and gp.gallery = ? limit $limit offset $offset
+where ($ingroups) and gp.gallery = ? limit $limit offset $offset
 EOT
 
 	my $cursor = $dbh->prepare($SQL);


Main Menu:

Site Tools:


Here, spammer, have some addresses.