hi all,
i have written the following code:
while(proceed !='Y' && proceed!='N' && proceed!='y' && proceed!='n')
{
printf("\nPress \n\t 'Y' or 'y' to continue \n\t 'N' or 'n' to cancel:");
scanf("%c",&proceed);
}
the output i am gettin is:
Press
'Y' to continue
... (1 Reply)
Hi,
I have a directory called logs in which i have the log files.
i have to touch the file before deleting it.
i am doing like this
filestodelete="*.log* *log*"
for files in $filestodelete
do
touch $files $files.$(date +%a)
rm -f $filestodelete
done
touch is not working... (5 Replies)
Hi guys my while do loop is not working properly;
As soon as the load_date and run_date is same it should stop can somebody tell me where I am having the problem?
In an oracle table I have
LOAD_DT=5/1/2009 DATE datatype
RUN_DT=5/5/2009 DATE datatype
Now in a script with a spool file I get the... (15 Replies)
Hi Guys,
This is my code.. I am getting an error in the inside while statement when comparing.. I am not able to figure it out.. Pls help me...
while read value fatherid son_id top_id r_type
do
inside_value=1;
echo $inside_value;
echo $r_type;
while
do
echo... (6 Replies)
hi
I had created a while loop in a script file called whiletest.sh as follows
as follows:
count=0
max=10
while
do
echo $count
echo count=$(count+1)" "
done
echo "value of count:$count"
then i run the script with the command
sh whilestest.sh
but its giving me an error... (5 Replies)
I have a while loop with -f and -o option.Can any one please tell me what that stands for?The Sample code is as follows:-
while
do
## some processing
done (10 Replies)
Hi Script Gurus,
I am facing issue with while loop in bash. The while loop is running as end less loop even after given criteria does not meet.
STATE_BEFORE_SPLIT () {
for clone in $Clonegroups; do
state=$( $Navicmd -listclone -name $clone -cloneid $Cloneid |awk... (3 Replies)
Hi,
I work on Ab-initio ETL tool which is based on Unix. I made a small script which has two loop's one with in another. All the functionality is working for the first line of outer loop but when it comes to other lines of outer loop it is throwing error as command not found. Below is the... (4 Replies)
I am trying to do a while do loop that asks for a password and returns if the password entered is incorrect. I have that part working however i want to modify it so that if a similar word is entered it will read "that is close but incorrect" and i cannot seem to get it working, being new in the... (6 Replies)
Hi all,
a problem with a loop. Imagine it starts with
var1="$(cat txtif.out )"while
do
echo file1
echo file2
echo y > txtif.out
if
then
break
fi
done
exit 0
the problem is that if the file is changing during the loop seems to continue as it reads "x" state,... (5 Replies)
Discussion started by: Board27
5 Replies
LEARN ABOUT DEBIAN
io::async::loop::poll
IO::Async::Loop::Poll(3pm) User Contributed Perl Documentation IO::Async::Loop::Poll(3pm)NAME
"IO::Async::Loop::Poll" - use "IO::Async" with "poll(2)"
SYNOPSIS
Normally an instance of this class would not be directly constructed by a program. It may however, be useful for runinng IO::Async with an
existing program already using an "IO::Poll" object.
use IO::Poll;
use IO::Async::Loop::Poll;
my $poll = IO::Poll->new;
my $loop = IO::Async::Loop::Poll->new( poll => $poll );
$loop->add( ... );
while(1) {
my $timeout = ...
my $ret = $poll->poll( $timeout );
$loop->post_poll;
}
DESCRIPTION
This subclass of "IO::Async::Loop" uses an "IO::Poll" object to perform read-ready and write-ready tests.
To integrate with existing code that uses an "IO::Poll", a "post_poll" can be called immediately after the "poll" method on the contained
"IO::Poll" object. The appropriate mask bits are maintained on the "IO::Poll" object when notifiers are added or removed from the set, or
when they change their "want_writeready" status. The "post_poll" method inspects the result bits and invokes the "on_read_ready" or
"on_write_ready" methods on the notifiers.
CONSTRUCTOR
$loop = IO::Async::Loop::Poll->new( %args )
This function returns a new instance of a "IO::Async::Loop::Poll" object. It takes the following named arguments:
"poll" The "IO::Poll" object to use for notification. Optional; if a value is not given, a new "IO::Poll" object will be constructed.
METHODS
$count = $loop->post_poll( $poll )
This method checks the returned event list from a "IO::Poll::poll" call, and calls any of the notification methods or callbacks that are
appropriate. It returns the total number of callbacks that were invoked; that is, the total number of "on_read_ready" and "on_write_ready"
callbacks for "watch_io", and "watch_time" event callbacks.
$poll Reference to the "IO::Poll" object
$count = $loop->loop_once( $timeout )
This method calls the "poll" method on the stored "IO::Poll" object, passing in the value of $timeout, and then runs the "post_poll" method
on itself. It returns the total number of callbacks invoked by the "post_poll" method, or "undef" if the underlying "poll" method returned
an error.
AUTHOR
Paul Evans <leonerd@leonerd.org.uk>
perl v5.14.2 2012-10-24 IO::Async::Loop::Poll(3pm)