unofficial mirror of bug-guile@gnu.org 
 help / color / mirror / Atom feed
* Fix for guile-www/cgi.scm (cgi:make-cookie)
@ 2003-08-28 14:53 Thamer Al-Harbash
  2003-08-29 10:44 ` Thien-Thi Nguyen
  2003-08-31 18:39 ` Marius Vollmer
  0 siblings, 2 replies; 6+ messages in thread
From: Thamer Al-Harbash @ 2003-08-28 14:53 UTC (permalink / raw)


This cgi::make-cookie breaks under guile-1.6 because it's using a
#&key and the (bound?) macro which seem to be no longer available
or depreciated. Please accept my patch below which fixes the
problem:

Index: cgi.scm
===================================================================
RCS file: /cvsroot/guile/guile/guile-www/cgi.scm,v
retrieving revision 1.6
diff -c -r1.6 cgi.scm
*** cgi.scm     27 Apr 2002 01:49:47 -0000      1.6
--- cgi.scm     28 Aug 2003 14:49:36 -0000
***************
*** 173,190 ****
      (and cookie-values (car cookie-values))))

  (define-public cgi:make-cookie
!   (lambda* (name value #&key path domain expires secure)
             (format #f "Set-Cookie: ~A=~A~A~A~A~A"
                     name value
!                    (if (bound? path)
                         (format #f "; path=~A" path) "")
!                    (if (bound? domain)
                         (format #f "; domain=~A" domain) "")
!                    (if (bound? expires)
                         (format #f "; expires=~A" expires) "")
!                    (if (and (bound? secure) secure)
                         "; secure" ""))))
-



  ;;; Internal functions.
--- 173,189 ----
      (and cookie-values (car cookie-values))))

  (define-public cgi:make-cookie
!   (lambda* (name value #:key path domain expires secure)
             (format #f "Set-Cookie: ~A=~A~A~A~A~A"
                     name value
!                    (if path
                         (format #f "; path=~A" path) "")
!                    (if domain
                         (format #f "; domain=~A" domain) "")
!                    (if expires
                         (format #f "; expires=~A" expires) "")
!                    (if secure
                         "; secure" ""))))



  ;;; Internal functions.


_______________________________________________
Bug-guile mailing list
Bug-guile@gnu.org
http://mail.gnu.org/mailman/listinfo/bug-guile


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2003-08-31 18:47 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-08-28 14:53 Fix for guile-www/cgi.scm (cgi:make-cookie) Thamer Al-Harbash
2003-08-29 10:44 ` Thien-Thi Nguyen
2003-08-29 13:00   ` Thamer Al-Harbash
2003-08-29 13:11     ` Thien-Thi Nguyen
2003-08-31 18:47   ` Marius Vollmer
2003-08-31 18:39 ` Marius Vollmer

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).