Enlightenment CVS committal

Author  : chaos
Project : e17
Module  : proto

Dir     : e17/proto/entropy/src


Modified Files:
        entropy_core.c 


Log Message:
* Handle paths better

===================================================================
RCS file: /cvs/e/e17/proto/entropy/src/entropy_core.c,v
retrieving revision 1.85
retrieving revision 1.86
diff -u -3 -r1.85 -r1.86
--- entropy_core.c      21 May 2006 01:52:31 -0000      1.85
+++ entropy_core.c      16 Jul 2006 05:59:33 -0000      1.86
@@ -1366,7 +1366,18 @@
 
        /*Do we have login information*/
        if (!source_file->username) {
-               snprintf(uri, 512, "%s://%s/%s",  source_file->uri_base, 
source_file->path, source_file->filename);
+               
+               /*Handle root path*/
+               if (strlen(source_file->path) > 0) { 
+                       if (!strcmp(source_file->path, "/")) {
+                                       snprintf(uri, 512, "%s:///%s",  
source_file->uri_base, 
+                                       source_file->filename);                 
                        
+                       } else {
+                                       snprintf(uri, 512, "%s://%s/%s",  
source_file->uri_base, 
+                                       source_file->path, 
source_file->filename);                      
+                       }
+               } else
+                       snprintf(uri, 512, "%s://%s",  source_file->uri_base, 
source_file->filename);
        } else {
                snprintf(uri, 512, "%s://%s:[EMAIL PROTECTED]/%s",  
source_file->uri_base, 
                source_file->username, source_file->password, 




-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
enlightenment-cvs mailing list
enlightenment-cvs@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs

Reply via email to