Changeset 1028 for trunk/dll/misc.c


Ignore:
Timestamp:
Jun 21, 2008, 8:35:16 PM (17 years ago)
Author:
Gregg Young
Message:

Fix for bug 237 that is actually correct; code clean up

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/dll/misc.c

    r1026 r1028  
    4545  19 Jun 08 JBS Ticket 239: Fix LoadDetailsSwitches so INI file is read correctly and details
    4646                switches are set correctly.
     47  21 Jun 08 GKY Fix LoadDetailsSwitches to actually use the keyroot value passed (change strcpy to strcat)
    4748
    4849***********************************************************************/
     
    12351236  strcat(s, ".");
    12361237  eos = &s[strlen(s)];
    1237   strcpy(eos, "DetailsLongname");
     1238  strcat(eos, "DetailsLongname");
    12381239  if (dcd)
    12391240    bool = &dcd->detailslongname;
     
    12431244  size = sizeof(BOOL);
    12441245  PrfQueryProfileData(fmprof, appname, s, (PVOID) bool, &size);
    1245   strcpy(eos, "DetailsSubject");
     1246  strcat(eos, "DetailsSubject");
    12461247  if (dcd)
    12471248    bool = &dcd->detailssubject;
     
    12511252  size = sizeof(BOOL);
    12521253  PrfQueryProfileData(fmprof, appname, s, (PVOID) bool, &size);
    1253   strcpy(eos, "DetailsEA");
     1254  strcat(eos, "DetailsEA");
    12541255  if (dcd)
    12551256    bool = &dcd->detailsea;
     
    12591260  size = sizeof(BOOL);
    12601261  PrfQueryProfileData(fmprof, appname, s, (PVOID) bool, &size);
    1261   strcpy(eos, "DetailsSize");
     1262  strcat(eos, "DetailsSize");
    12621263  if (dcd)
    12631264    bool = &dcd->detailssize;
     
    12671268  size = sizeof(BOOL);
    12681269  PrfQueryProfileData(fmprof, appname, s, (PVOID) bool, &size);
    1269   strcpy(eos, "DetailsIcon");
     1270  strcat(eos, "DetailsIcon");
    12701271  if (dcd)
    12711272    bool = &dcd->detailsicon;
     
    12751276  size = sizeof(BOOL);
    12761277  PrfQueryProfileData(fmprof, appname, s, (PVOID) bool, &size);
    1277   strcpy(eos, "DetailsAttr");
     1278  strcat(eos, "DetailsAttr");
    12781279  if (dcd)
    12791280    bool = &dcd->detailsattr;
     
    12831284  size = sizeof(BOOL);
    12841285  PrfQueryProfileData(fmprof, appname, s, (PVOID) bool, &size);
    1285   strcpy(eos, "DetailsCRDate");
     1286  strcat(eos, "DetailsCRDate");
    12861287  if (dcd)
    12871288    bool = &dcd->detailscrdate;
     
    12911292  size = sizeof(BOOL);
    12921293  PrfQueryProfileData(fmprof, appname, s, (PVOID) bool, &size);
    1293   strcpy(eos, "DetailsCRTime");
     1294  strcat(eos, "DetailsCRTime");
    12941295  if (dcd)
    12951296    bool = &dcd->detailscrtime;
     
    12991300  size = sizeof(BOOL);
    13001301  PrfQueryProfileData(fmprof, appname, s, (PVOID) bool, &size);
    1301   strcpy(eos, "DetailsLWDate");
     1302  strcat(eos, "DetailsLWDate");
    13021303  if (dcd)
    13031304    bool = &dcd->detailslwdate;
     
    13071308  size = sizeof(BOOL);
    13081309  PrfQueryProfileData(fmprof, appname, s, (PVOID) bool, &size);
    1309   strcpy(eos, "DetailsLWTime");
     1310  strcat(eos, "DetailsLWTime");
    13101311  if (dcd)
    13111312    bool = &dcd->detailslwtime;
     
    13151316  size = sizeof(BOOL);
    13161317  PrfQueryProfileData(fmprof, appname, s, (PVOID) bool, &size);
    1317   strcpy(eos, "DetailsLADate");
     1318  strcat(eos, "DetailsLADate");
    13181319  if (dcd)
    13191320    bool = &dcd->detailsladate;
     
    13231324  size = sizeof(BOOL);
    13241325  PrfQueryProfileData(fmprof, appname, s, (PVOID) bool, &size);
    1325   strcpy(eos, "DetailsLATime");
     1326  strcat(eos, "DetailsLATime");
    13261327  if (dcd)
    13271328    bool = &dcd->detailslatime;
     
    13311332  size = sizeof(BOOL);
    13321333  PrfQueryProfileData(fmprof, appname, s, (PVOID) bool, &size);
    1333   strcpy(eos, "SubjectInLeftPane");
     1334  strcat(eos, "SubjectInLeftPane");
    13341335  if (dcd)
    13351336    bool = &dcd->fSubjectInLeftPane;
     
    13391340  size = sizeof(BOOL);
    13401341  PrfQueryProfileData(fmprof, appname, s, (PVOID) bool, &size);
    1341   strcpy(eos, "SubjectLengthMax");
     1342  strcat(eos, "SubjectLengthMax");
    13421343  if (dcd)
    13431344    bool = &dcd->fSubjectLengthMax;
     
    13511352      dcd->SubjectDisplayWidth = 0;
    13521353    else {
    1353       strcpy(eos, "SubjectDisplayWidth");
     1354      strcat(eos, "SubjectDisplayWidth");
    13541355      bool = &dcd->SubjectDisplayWidth;
    13551356      *bool = SubjectDisplayWidth;
     
    13661367      SubjectDisplayWidth = 0;
    13671368    else {
    1368       strcpy(eos, "SubjectDisplayWidth");
     1369      strcat(eos, "SubjectDisplayWidth");
    13691370      bool = &SubjectDisplayWidth;
    13701371      *bool = SubjectDisplayWidth;
Note: See TracChangeset for help on using the changeset viewer.