question on zenity centos 5

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]



I am trying to use zenity --progress.

When I use this script:
#!/bin/sh
(
echo "10" ; sleep 1
echo "20" ; sleep 1
echo "50" ; sleep 1
echo "75" ; sleep 1
echo "100" ; sleep 1
) | zenity --progress
~

It works fine...

When I use a little program.
               for(count = 0; count <= 100; count += 10)
                       {
                       printf(stdout, "%d\n", count);
                       sleep(1);
                       }

and run it as "myprog | zenity --progress"
I dont get anything updating until the end and the program exits.

Why does the second example not work. Both
are just piping stdout into zenity. Both use carriage return.

Thanks,

Jerry
_______________________________________________
CentOS mailing list
CentOS@xxxxxxxxxx
http://lists.centos.org/mailman/listinfo/centos

[Index of Archives]     [CentOS]     [CentOS Announce]     [CentOS Development]     [CentOS ARM Devel]     [CentOS Docs]     [CentOS Virtualization]     [Carrier Grade Linux]     [Linux Media]     [Asterisk]     [DCCP]     [Netdev]     [Xorg]     [Linux USB]
  Powered by Linux