/[gentoo-src]/Xorgautoconfig/Xorgautoconfig.c
Gentoo

Diff of /Xorgautoconfig/Xorgautoconfig.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 1.4 Revision 1.5
208 208
209 findVideoDevice(); /* For BusID */ 209 findVideoDevice(); /* For BusID */
210 210
211 /* Let's be nice and backup an existing xorg.conf */ 211 /* Let's be nice and backup an existing xorg.conf */
212 if ((f = fopen("/etc/X11/xorg.conf", "r"))) { 212 if ((f = fopen("/etc/X11/xorg.conf", "r"))) {
213 system("mv /etc/X11/xorg.conf /etc/X11/xorg.xorgautoconfig"); 213 system("mv /etc/X11/xorg.conf /etc/X11/xorg.conf.autobak");
214 printf("The current xorg.conf has been copied into /etc/X11/xorg.conf.autobak\n");
214 } 215 }
215 216
217 /* Check the permissions for writing */
216 if (!(f = fopen("/etc/X11/xorg.conf", "w"))) { 218 if (!(f = fopen("/etc/X11/xorg.conf", "w"))) {
217 fprintf(stderr, "Can't write to /etc/X11/xorg.conf. Exiting.\n"); 219 fprintf(stderr, "Can't write to /etc/X11/xorg.conf. Exiting.\n");
218 return -1;; 220 return -1;;
219 } 221 }
220 222

Legend:
Removed from v.1.4  
changed lines
  Added in v.1.5

  ViewVC Help
Powered by ViewVC 1.1.20