Feature request

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Feature request

Eugen Konkov-3
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
[hidden email]
http://lists.nongnu.org/mailman/listinfo/microdc-devel
Reply | Threaded
Open this post in threaded view
|

Re: Feature request

Yaohan Chen
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
> [hidden email]
> http://lists.nongnu.org/mailman/listinfo/microdc-devel



_______________________________________________
microdc-devel mailing list
[hidden email]
http://lists.nongnu.org/mailman/listinfo/microdc-devel