[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [microdc-devel] Feature request
From: |
Yaohan Chen |
Subject: |
Re: [microdc-devel] Feature request |
Date: |
Mon, 4 Aug 2008 03:07:06 -0400 |
User-agent: |
KMail/1.10.0 (Linux/2.6.24-20-generic; KDE/4.1.0; i686; ; ) |
You can use "screen" to run any console program "in background". Read
<http://www.kuro5hin.org/story/2004/3/9/16838/14935>, or search for "GNU
screen" for another tutorial or read its manpage.
On Sunday 03 August 2008 17:05:10 KES wrote:
> Hi
>
> Can you add feature that will allow to run microdc2 in background.
>
> It is usefull to share some files on server and not require manually each
> time run microdc2...
>
> I have tryied a little, but my patch has some problems:
>
> 1. all output are performed to active console
>
> 2. some times it is core dumping
>
> 3. some times it is exited....
>
>
>
> It would be very well if you add ability to run microdc2 as daemon
>
> I hope my patch will help little:
>
>
>
> command.c
>
> 63a64
>
> > static void cmd_demonize(int argc, char **argv);
>
> 232a234,236
>
> > add_builtin_command("demonize", cmd_demonize, NULL,
> >
> > _("demonize"),
> >
> > _("Try to demonize\n"));
>
> 1383a1388,1400
>
> > cmd_demonize(int argc, char **argv)
> >
> > {
> >
> > screen_suspend();
> >
> > pid_t child = fork();
> >
> > if( child == 0 ) {
> >
> > warn_writer = default_warn_writer;
> >
> > return;
> >
> > }
> >
> >
> >
> > running = false;
> >
> > }
> >
> >
> >
> > static void
>
> thank you very match
>
>
> _______________________________________________
> microdc-devel mailing list
> address@hidden
> http://lists.nongnu.org/mailman/listinfo/microdc-devel