G'day Ken,

Thanks for the references. Let me try to explain the problem on which I am working.

I need to scan a set of directory and based on certain criteria I may need to perform a tar operation. Once the operation is successful I need to update some entries in DB( a SQLite DB).

Now the issue is say an user use Ctrl-C to abort the program. As it may come while DB operations going on it will result into a inconsistent state of DB (which need to be avoided). As if the program run again the flow will be decided based on the entries in DB.

So there are two ways to handle such case

1. Catch all such signals and let the program run

2. Catch such signals and handle the condition gracefully.

So I am thinking to take approach 2 for the same. So I was thinking how to achieve the same. Any example with this reference will be great help.

Hope this will help.


In reply to Re^2: Need suggestion for selecting IPC::Open3 or backticks by techman2006
in thread Need suggestion for selecting IPC::Open3 or backticks by techman2006

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.