Mailing List Archive

[PATCH] setup should warn before clearing the database
Hi Isaac,

I re-ran the mythtv setup program just for fun. I quit out once I
remembered what it did, but it was too late. It had deleted all of my
program/channel/recording/card info from the database. I'm not
sure why it needs to do this, but I am sure that it should at
least warn before doing so. :-)

Thanks for all you work on MythTV,
-Jim

Index: main.cpp
===================================================================
RCS file: /var/lib/cvs/MC/setup/main.cpp,v
retrieving revision 1.4
diff -u -r1.4 main.cpp
--- main.cpp 3 Oct 2002 20:06:34 -0000 1.4
+++ main.cpp 15 Oct 2002 06:40:21 -0000
@@ -354,6 +354,9 @@
if (!dir.exists())
dir.mkdir(fileprefix);

+ if("y" != getResponse("This will clear all program/channel/recording/card info from the database. Proceed?","y"))
+ exit(1);
+
clearDB();

getCaptureCards();
Re: [PATCH] setup should warn before clearing the database [ In reply to ]
On Tuesday 15 October 2002 02:46 am, Jim Radford wrote:
> Hi Isaac,
>
> I re-ran the mythtv setup program just for fun. I quit out once I
> remembered what it did, but it was too late. It had deleted all of my
> program/channel/recording/card info from the database. I'm not
> sure why it needs to do this, but I am sure that it should at
> least warn before doing so. :-)

Thanks, that's exactly how I like to get bug reports =) Committed to CVS.

It needs to delete things because the setup is fairly braindead.. I'm planning
on making it better once it goes graphical, but, it's good enough for now.

Isaac