Author Topic: wget update killed my program ;o(  (Read 1293 times)

Offline zerocool

  • Sr. Member
  • ****
  • Posts: 374
wget update killed my program ;o(
« on: November 02, 2011, 07:59:40 AM »

I have a perl script which contains a call to wget as follows:

system ('wget -O ~/tmp/video.jpg http://user:password@192.168.1.106:80/cgi-bin/video.jpg -o /dev/null 2>&1');

This has been working fine for the last 5 months until the recent wget update a few days ago. I've been trying to figure out how to change the call to fix the problem but... ahhhhh

Anyone have any ideas? I've tried using --http-user= and http-password= but that didn't seem to work either.

The output from wget at the cl says 401 unauthorized and the image file in tmp (it does create the video.jpg file in tmp) is an empty file...

This seems to be a bug in the new wget as far as I can tell. There's nothing wrong with my syntax (again, as far as I can tell...).
 :'(

thanks in advance for any help.

 

Offline Neal ManBear

  • Administrator
  • Super Villain
  • *****
  • Posts: 15845
  • LXDE! Coffee, Bacon and Cheesecake!
Re: wget update killed my program ;o(
« Reply #1 on: November 02, 2011, 08:20:01 AM »
Perhaps there was some change in wget that affects your script. Have you looked up the changelog for this update?     

Offline zerocool

  • Sr. Member
  • ****
  • Posts: 374
Re: wget update killed my program ;o(
« Reply #2 on: November 02, 2011, 09:02:34 AM »
Perhaps there was some change in wget that affects your script. Have you looked up the changelog for this update?     

Perhaps and no I haven't look at the changelog but I did check the syntax at the GNU Wget 1.13.4 web site. It says this should still work...

I'll see if I can find the changelog on the web.

Thanks for the advice Neal. ps, love lxde great job.


Offline muungwana

  • Hero Member
  • *****
  • Posts: 6235
Re: wget update killed my program ;o(
« Reply #3 on: November 02, 2011, 09:22:20 AM »

run on the terminal "wget" with those options but without the "-o /dev/null 2>&1" part and see what error msg you get if any.
.. 3 things are certain in life : death, taxes and software bloat ..
.. tell me something i don't know, something i can use as i struggle to reason with the world around me ..

Offline zerocool

  • Sr. Member
  • ****
  • Posts: 374
Re: wget update killed my program ;o(
« Reply #4 on: November 02, 2011, 10:06:02 AM »
Yeah, I have. That's what I meant when I said it gives a 401 unauthorized when run at the cl.

I'm sure the problem is wget is no longer able to logon to the server the way it used to before the update...

The question is why?

Stll have to check the change log (when I get the time to do it)...


Offline kjpetrie

  • PCLinuxOS Tester
  • Hero Member
  • *******
  • Posts: 3984
Re: wget update killed my program ;o(
« Reply #5 on: November 02, 2011, 03:54:58 PM »
The Changelog is at /usr/share/doc/wget/ChangeLog. No need to go online.

Are you sure it's a change to wget and not the website? Can you download the file with a normal browser?
-----------
KJP
-----------------------------------------------------------
PClos64 RC1 on Intel D945GCLF2 motherboard (Atom 330), 2GB DDR2 RAM, Maxtor STM325031, HL-DT-ST DVDRAM GSA-H42N, Amilo LSL 3220T monitor. Also Acer 5810TG (with custom kernel) and Asus eeePC 2G surf

Offline zerocool

  • Sr. Member
  • ****
  • Posts: 374
Re: wget update killed my program ;o(
« Reply #6 on: November 02, 2011, 04:42:40 PM »
The Changelog is at /usr/share/doc/wget/ChangeLog. No need to go online.

Are you sure it's a change to wget and not the website? Can you download the file with a normal browser?


Thanks for the info. on the changelog. I did not know that.

And yeah I'm sure. The image is not comming from the internet but rather the intranet (note the local ip). It's from one of my ip cameras and yes I can  download the file with a normal browser with no problem.

I'm fairly confident the problem is with wget. 99.99% sure of that.


Offline zerocool

  • Sr. Member
  • ****
  • Posts: 374
Re: wget update killed my program ;o(
« Reply #7 on: November 03, 2011, 09:43:41 AM »
So, I removed the security from the camera, change the call to wget to:

system ('wget -O ~/tmp/video.jpg http://192.168.1.106:80/cgi-bin/video.jpg -o /dev/null 2>&1');

and the program works. I guess I'll have to wait for wget guys to fix this bug?
The Change log didn't show anything that should have caused a problem that
I could see anyway. Very strange.

 

Offline Neal ManBear

  • Administrator
  • Super Villain
  • *****
  • Posts: 15845
  • LXDE! Coffee, Bacon and Cheesecake!
Re: wget update killed my program ;o(
« Reply #8 on: November 03, 2011, 11:23:46 AM »
Did you report the bug to the wget guys?     

Offline zerocool

  • Sr. Member
  • ****
  • Posts: 374
Re: wget update killed my program ;o(
« Reply #9 on: November 04, 2011, 08:02:08 AM »

Someone beat me to it.

http://savannah.gnu.org/bugs/index.php?34141

At least we know I not the only one...


« Last Edit: November 04, 2011, 08:11:19 AM by zerocool »