Enlightenment CVS committal
Author : sarajervi
Project : misc
Module : erss
Dir : misc/erss/src
Modified Files:
erss.c parse.c
Log Message:
display help when the rc file doesnt exist
===================================================================
RCS file: /cvsroot/enlightenment/misc/erss/src/erss.c,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -3 -r1.9 -r1.10
--- erss.c 9 Jan 2004 23:00:08 -0000 1.9
+++ erss.c 10 Jan 2004 19:34:00 -0000 1.10
@@ -504,13 +504,16 @@
}
- if (parse_rc_file ())
+ if (parse_rc_file ()) {
+ printf ("Found the rc file\n");
got_rc_file = TRUE;
+ }
if(!got_config_file) {
- if (!got_rc_file)
+ if (!got_rc_file) {
display_default_usage ();
+ }
else
parse_config_file (rc->config);
===================================================================
RCS file: /cvsroot/enlightenment/misc/erss/src/parse.c,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -3 -r1.5 -r1.6
--- parse.c 9 Jan 2004 23:00:08 -0000 1.5
+++ parse.c 10 Jan 2004 19:34:00 -0000 1.6
@@ -276,6 +276,9 @@
fp = fopen (file, "r");
+ if (!fp)
+ return FALSE;
+
while (fp && (line = get_next_line (fp)) != NULL)
{
if ((c = get_element (&line, "config")) != NULL)
@@ -408,7 +411,7 @@
if (cfg->clock != 1 && cfg->clock != 0)
{
fprintf (stderr,
- "ERROR: Clock option has wrong value -
check your config file!\n");
+ "Erss error: Clock option has wrong
value - check your config file!\n");
exit (-1);
}
continue;
@@ -421,7 +424,7 @@
if (cfg->num_stories > 10)
{
fprintf (stderr,
- "ERROR: Max stories to show is 10 -
check your config file!\n");
+ "Erss error: Max stories to show is
10 - check your config file!\n");
exit (-1);
}
continue;
@@ -434,7 +437,7 @@
if (cfg->borderless != 1 && cfg->borderless != 0)
{
fprintf (stderr,
- "ERROR: Borderless option has wrong
value - check your config file!\n");
+ "Erss error:: Borderless option has
wrong value - check your config file!\n");
exit (-1);
}
continue;
-------------------------------------------------------
This SF.net email is sponsored by: Perforce Software.
Perforce is the Fast Software Configuration Management System offering
advanced branching capabilities and atomic changes on 50+ platforms.
Free Eval! http://www.perforce.com/perforce/loadprog.html
_______________________________________________
enlightenment-cvs mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs