Changeset 5490 for trunk/Nebulous-Server/lib/Nebulous/Server.pm
- Timestamp:
- Nov 8, 2005, 3:31:07 PM (21 years ago)
- File:
-
- 1 edited
-
trunk/Nebulous-Server/lib/Nebulous/Server.pm (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/Nebulous-Server/lib/Nebulous/Server.pm
r5487 r5490 1 1 # Copyright (c) 2004 Joshua Hoblitt 2 2 # 3 # $Id: Server.pm,v 1.1 2 2005-11-09 00:48:24jhoblitt Exp $3 # $Id: Server.pm,v 1.13 2005-11-09 01:31:07 jhoblitt Exp $ 4 4 5 5 package Nebulous::Server; … … 17 17 use Log::Log4perl; 18 18 use Params::Validate qw( validate_pos SCALAR ); 19 20 my %class = (21 raw => 1,22 );23 19 24 20 my $log; … … 99 95 100 96 # check that the comment isn't too long 97 # check that the volume requested is valid 98 101 99 # check that the class requested is valid 102 # check that the volume requested is valid 100 if ( $class ) { 101 my $class_id; 102 eval { 103 my $query = $db->prepare_cached( $sql->get_class ); 104 $query->execute( $class ); 105 ( $class_id ) = $query->fetchrow_array; 106 107 $query->finish; 108 }; 109 if ( $@ ) { 110 $db->rollback; 111 $log->logdie( "database error: $@" ); 112 } 113 114 unless ( $class_id ) { 115 $log->logdie( "Invalid class ID: $class" ); 116 } 117 } 103 118 104 119 my $uri;
Note:
See TracChangeset
for help on using the changeset viewer.
