aMule Forum

Please login or register.

Login with username, password and session length
Advanced search  

News:

We're back! (IN POG FORM)

Author Topic: alcc and stdout - redirecting not possible  (Read 2657 times)

joker4791

  • Approved Newbie
  • *
  • Karma: 1
  • Offline Offline
  • Posts: 25
alcc and stdout - redirecting not possible
« on: March 10, 2010, 10:38:05 AM »

Hi,

I'm stuck with redirecting output from alcc to file or variable.
Code: [Select]
server:~# alcc ooo_3.2.0_win32intel_install_wjre_de.exe
Bitte warten...
ooo_3.2.0_win32intel_install_wjre_de.exe ---> ed2k://|file|ooo_3.2.0_win32intel_install_wjre_de.exe|167555440|02c07bfebab09d914acce413f89813cd|/

server:~# alcc ooo_3.2.0_win32intel_install_wjre_de.exe > /tmp/temp.txt
Bitte warten...
ooo_3.2.0_win32intel_install_wjre_de.exe ---> ed2k://|file|ooo_3.2.0_win32intel_install_wjre_de.exe|167555440|02c07bfebab09d914acce413f89813cd|/

server:~# cat /tmp/temp.txt
server:~# /usr/local/bin/alcc ooo_3.2.0_win32intel_install_wjre_de.exe
ed2k://|file|ooo_3.2.0_win32intel_install_wjre_de.exe|167555440|02c07bfebab09d914acce413f89813cd|/
server:~# /usr/local/bin/alcc ooo_3.2.0_win32intel_install_wjre_de.exe > /tmp/temp.txt
ed2k://|file|ooo_3.2.0_win32intel_install_wjre_de.exe|167555440|02c07bfebab09d914acce413f89813cd|/
server:~# cat /tmp/temp.txt
server:~# VAR="`/usr/local/bin/alcc ooo_3.2.0_win32intel_install_wjre_de.exe`"
ed2k://|file|ooo_3.2.0_win32intel_install_wjre_de.exe|167555440|02c07bfebab09d914acce413f89813cd|/
server:~# echo $VAR

server:~#
What's the trick, or does alcc need to be patched to be able to output data to other than stdout?

My system:
Code: [Select]
Linux server 2.6.26-2-amd64 #1 SMP Tue Jan 12 22:12:20 UTC 2010 x86_64 GNU/Linux
Debian Lenny 5.0r4 with self compiled aMule 2.2.6 (/usr/local/bin/...) and amule-utils (2.2.1) from distro.

Regards,
joker
Logged
for windows problems: reboot - for linux problems: be root!

Kry

  • Ex-developer
  • Retired admin
  • Hero Member
  • *****
  • Karma: -665
  • Offline Offline
  • Posts: 5795
Re: alcc and stdout - redirecting not possible
« Reply #1 on: March 10, 2010, 11:05:04 AM »

Did you try "2>" indtead of ">" ?

I have the feeling it may be sent to stderr. If that works, it needs to be changed.
Logged

joker4791

  • Approved Newbie
  • *
  • Karma: 1
  • Offline Offline
  • Posts: 25
Re: alcc and stdout - redirecting not possible
« Reply #2 on: March 10, 2010, 11:27:16 AM »

Hi,

thanks, that did the trick ;) .
Code: [Select]
server:~# /usr/local/bin/alcc ooo_3.2.0_win32intel_install_wjre_de.exe 2> /tmp/temp.txt
server:~# cat /tmp/temp.txt
ed2k://|file|ooo_3.2.0_win32intel_install_wjre_de.exe|167555440|02c07bfebab09d914acce413f89813cd|/
server:~#

Regards,
joker
Logged
for windows problems: reboot - for linux problems: be root!

Stu Redman

  • Administrator
  • Hero Member
  • *****
  • Karma: 214
  • Offline Offline
  • Posts: 3739
  • Engines screaming
Re: alcc and stdout - redirecting not possible
« Reply #3 on: March 10, 2010, 10:15:34 PM »

Fixed in SVN since 9912.
Logged
The image of mother goddess, lying dormant in the eyes of the dead, the sheaf of the corn is broken, end the harvest, throw the dead on the pyre -- Iron Maiden, Isle of Avalon

Vollstrecker

  • Administrator
  • Hero Member
  • *****
  • Karma: 67
  • Offline Offline
  • Posts: 1549
  • Unofficial Debian Packager
    • http://vollstreckernet.de
Re: alcc and stdout - redirecting not possible
« Reply #4 on: March 11, 2010, 04:58:26 PM »

Debian Lenny 5.0r4 with self compiled aMule 2.2.6 (/usr/local/bin/...) and amule-utils (2.2.1) from distro.

Bad combination anyway.
Logged
Homefucking is killing prostitution