php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #30058 Yet Another Solaris compilation problem :-((
Submitted: 2004-09-10 22:46 UTC Modified: 2004-12-07 01:00 UTC
Votes:1
Avg. Score:5.0 ± 0.0
Reproduced:1 of 1 (100.0%)
Same Version:0 (0.0%)
Same OS:1 (100.0%)
From: l_faillie at yahoo dot com Assigned:
Status: No Feedback Package: FTP related
PHP Version: 4.3.8 OS: Solaris 8
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: l_faillie at yahoo dot com
New email:
PHP Version: OS:

 

 [2004-09-10 22:46 UTC] l_faillie at yahoo dot com
Description:
------------
Hi all,

I'm working on a script to update a web site using ftp_* functions using CLI version of PHP.

Unfortunatly, it doesn't work because all calls to ftp_put() fail w/o anything displayed. There is also some ftp_chdir() and ftp_pwd() in my script and they work correctly : the problem is only w/ ftp_put().

I have added some puts() inside php's code, made some checks and I think the problem comes from the scripting engine as PHP_FUNCTION(ftp_fput) of ext/ftp/php_ftp.c  is never called.

I think also it's related to my own compilation environment under Solaris 8 because I build PHP on my HP-UX 10.20 workstation at work and I don't have this bug.

Questions :
- does someone know if there is issue w/ Solaris 8 or 1 year old GNU tool ?

- where can I put breakpoint using gdb to know what's append just before ftp_put is called ?

Thanks for your help.

Laurent



Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2004-09-11 00:44 UTC] l_faillie at yahoo dot com
no, same result :-(
 [2004-09-20 20:53 UTC] l_faillie at yahoo dot com
Sample source code :

#!/usr/local/bin/php
<?php
/****
 * Parametres de connection
 ****/
         // Pour RA
    $usr = 'le_user';
    $pwd = 'le_passwd';
    $srv = 'ra.chez.moi';
    $sroot = '/web';

/****
 * Ouverture du FTP
 ****/
    $con = ftp_connect($srv) or die(1);
    ftp_login($con, $usr, $pwd) or die(1);
    ftp_chdir($con, $sroot) or die(1);

    echo '*D* Le repertoire courant est :', $home = ftp_pwd($con), "\n";

    $fch='galerie/Italie/LacMajeur/Baveno/index.php' 

        $dir = dirname($fch);
        $ndir = substr_count($dir,'/')+1;

        ftp_chdir($con, $dir) or die(1);
 
        echo     ftp_pwd($con),' & ', getcwd(), basename($fch),"\n";
        ftp_put($con, basename($fch), basename($fch), FTP_BINARY) or die("*F*pb de put\n");
 

    ftp_close($con);
    echo "C'est fini !\n";
?>

Bye
 [2004-09-28 23:26 UTC] sniper@php.net
add 'error_reporting(E_ALL);' as first line in your script and also run it on the CLI binary of PHP. Report here what error messages you get. Also, with what compiler did you compile PHP? (version!)

 [2006-06-08 13:22 UTC] khaja_q at yahoo dot com
Me too facing same problem.
PHP Version 4.4.1
SunOS 
'./configure' '--with-apache=../apache_1.3.34' '--with-mysql' '--with-zlib' '--with-mhash' '--with-gd' '--with-freetype-dir=../freetype-2.1.10' '--enable-ftp' '--with-openssl=/usr/local/ssl'
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Wed Apr 24 13:01:29 2024 UTC