Send CDR to Serial or Sockets

Hi All.
I have a Perl script that with the help of Cron will perform a “tail” command on Master.csv then send the last line of data (as tail does) via a serial port to a 3rd party Call Logging application.
At the moment, this works fine, BUT I go to thinking, well, why not just send the data from the cdr app. that writes say to the csv file. i.e write to the csv file, oh, and while your at it, send the same data via serial or TCP/IP too.

I can see where abouts in the cdr-csv.c file I would add this code, but 2 small issues, 1. whilst I can read C its been a NUMBER of years since I had to write any C (Delphi/.Net developer for a job now days) and 2. not sure if I tried to compile the code it would compile for me.

So, I am keen to know if anyone has done a similar thing, if it wold be feasible to do it, and if anyone could help.

Thanks, Jeremy