/* existence tests */ void adatet(const struct etent *etptr) { switch (etptr->et_type) { case EXISTS: structcheck(etptr->et_tname, etptr->et_incl, etptr->et_struct, etptr->et_field, etptr->et_offset, etptr->et_value); break; case ALIAS: aliascheck(etptr->et_tname, etptr->et_incl, etptr->et_struct, etptr->et_field, etptr->et_dname); break; case VALUE: valuecheck(etptr->et_tname, etptr->et_incl, etptr->et_struct, etptr->et_dname); break; case DEFINED: funccheck(etptr->et_tname, etptr->et_incl, etptr->et_struct); break; default: tst_resm(TBROK, "invalid type %d", etptr->et_type); break; } }
/* existence tests */ void icmp6_et(void) { int i; for (i = 0; i < ETCOUNT; ++i) { switch (etab[i].et_type) { case EXISTS: structcheck(etab[i].et_tname, etab[i].et_incl, etab[i].et_struct, etab[i].et_field, etab[i].et_offset, etab[i].et_value); break; case ALIAS: aliascheck(etab[i].et_tname, etab[i].et_incl, etab[i].et_struct, etab[i].et_field, etab[i].et_dname); break; case VALUE: valuecheck(etab[i].et_tname, etab[i].et_incl, etab[i].et_struct, etab[i].et_dname); break; case DEFINED: funccheck(etab[i].et_tname, etab[i].et_incl, etab[i].et_struct); break; default: tst_resm(TBROK, "invalid type %d", etab[i].et_type); break; } } }
BOOL CNewProj::OnKillActive( ) { CString st; char tempo[HTS_URLMAXSIZE*2]; GetDlgItemText(IDC_projpath,st); if (st.GetLength() > MAX_PATH) { return FALSE; } strcpybuff(tempo,st); if ((tempo[strlen(tempo)-1]=='/') || (tempo[strlen(tempo)-1]=='\\')) { tempo[strlen(tempo)-1]='\0'; SetDlgItemTextCP(this, IDC_projpath,tempo); } UpdateData(TRUE); // DoDataExchange // créer structure { char dest[HTS_URLMAXSIZE*2]; int i=0; strcpybuff(dest,GetPath()+"hts-cache\\"); { char* a; while(a=strchr(dest,'\\')) *a='/'; structcheck(dest); } } CShellApp_app->end_path=dialog0->GetBasePath(); CShellApp_app->end_path_complete=dialog0->GetPath(); Build_TopIndex(FALSE); // structure visible TStamp t_start = mtime_local(); // FIXME: VERY SLOW!! this_DirTreeView->EnsureVisible(GetPath()+"hts-cache"); TStamp t_end = mtime_local(); //TStamp l_dir = t_end - t_start; //CString a; //a.Format("t=%dms", (int)l_dir); //(void) AfxMessageBox(a, MB_OK); // charger préfs dialog1->OnChangepathlog(); return 1; }
int main(int argc, char *argv[]) { int i, lc; char *msg; /* Parse standard options given to run the test. */ msg = parse_opts(argc, argv, (option_t *)NULL, NULL); if (msg != (char *)NULL) { tst_brkm(TBROK, tst_exit, "OPTION PARSING ERROR - %s", msg); } setup(); for (lc = 0; TEST_LOOPING(lc); ++lc) { for (i=0; i<FTCOUNT; ++i) { switch (ftab[i].ft_type) { case EXISTS: structcheck(ftab[i].ft_tname, ftab[i].ft_incl, ftab[i].ft_struct, ftab[i].ft_field, ftab[i].ft_offset, ftab[i].ft_value); break; case ALIAS: aliascheck(ftab[i].ft_tname, ftab[i].ft_incl, ftab[i].ft_struct, ftab[i].ft_field, ftab[i].ft_dname); break; case VALUE: valuecheck(ftab[i].ft_tname, ftab[i].ft_incl, ftab[i].ft_struct, ftab[i].ft_dname); break; default: tst_resm(TBROK, "invalid type %d", ftab[i].ft_type); break; } } } cleanup(); /* NOTREACHED */ return 0; }
void do_test(const struct ftent *ftptr) { switch (ftptr->ft_type) { case EXISTS: structcheck(ftptr->ft_tname, ftptr->ft_incl, ftptr->ft_struct, ftptr->ft_field, ftptr->ft_offset, ftptr->ft_value); break; case ALIAS: aliascheck(ftptr->ft_tname, ftptr->ft_incl, ftptr->ft_struct, ftptr->ft_field, ftptr->ft_dname); break; case VALUE: valuecheck(ftptr->ft_tname, ftptr->ft_incl, ftptr->ft_struct, ftptr->ft_dname); break; default: tst_resm(TBROK, "invalid type %d", ftptr->ft_type); break; } }