[bknr-cvs] r2431 - branches/trunk-reorg/projects/quickhoney/src
hhubner at common-lisp.net
hhubner at common-lisp.net
Thu Jan 31 10:51:58 UTC 2008
Author: hhubner
Date: Thu Jan 31 05:51:58 2008
New Revision: 2431
Modified:
branches/trunk-reorg/projects/quickhoney/src/handlers.lisp
branches/trunk-reorg/projects/quickhoney/src/init.lisp
Log:
Produce warning message for invalid query.
Change path in library loading hack.
Modified: branches/trunk-reorg/projects/quickhoney/src/handlers.lisp
==============================================================================
--- branches/trunk-reorg/projects/quickhoney/src/handlers.lisp (original)
+++ branches/trunk-reorg/projects/quickhoney/src/handlers.lisp Thu Jan 31 05:51:58 2008
@@ -122,7 +122,12 @@
(let ((preproduced-buttons (buttons-for-category category subcategory)))
(if preproduced-buttons
(format nil "/image/~D" (store-object-id (random-elt preproduced-buttons)))
- (format nil "/image/~D/cutout-button,~(~A~),~A" (store-object-id (random-elt (subseq (images-sorted-by-time category subcategory) 0 10))) subcategory background-color))))
+ (let ((images (images-sorted-by-time category subcategory)))
+ (if images
+ (format nil "/image/~D/cutout-button,~(~A~),~A"
+ (store-object-id (random-elt (subseq images 0 10)))
+ subcategory background-color)
+ (warn "No images for ~A ~A found"category subcategory))))))
(defun find-button-images (query-elements)
(loop for (category-string subcategories-string) on query-elements by #'cddr
Modified: branches/trunk-reorg/projects/quickhoney/src/init.lisp
==============================================================================
--- branches/trunk-reorg/projects/quickhoney/src/init.lisp (original)
+++ branches/trunk-reorg/projects/quickhoney/src/init.lisp Thu Jan 31 05:51:58 2008
@@ -4,7 +4,10 @@
(setq cxml::*default-catalog* '("/home/hans/share/xml/catalog"))
;; XXX hack hack hack
(mapcar #'cl-gd::load-foreign-library
- '("/usr/lib/libcrypto.so" "/usr/lib/libssl.so" "/usr/local/lib/libgd.so" "/home/hans/bknr-svn/thirdparty/cl-gd/cl-gd-glue.so"))
+ '("/usr/lib/libcrypto.so"
+ "/usr/lib/libssl.so"
+ "/usr/local/lib/libgd.so"
+ "/home/hans/bknr-svn/thirdparty/cl-gd-0.5.6/cl-gd-glue.so"))
(when *store*
(close-store))
(make-instance 'store
More information about the Bknr-cvs
mailing list