Ignore:
Timestamp:
Apr 10, 2013 12:58:16 PM (6 years ago)
Author:
stefan
Message:

sync with trunk rev 1901

Location:
stable/2.8/Cbc
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • stable/2.8/Cbc

  • stable/2.8/Cbc/examples/sample1.cpp

    r1660 r1902  
    4343  struct rusage usage;
    4444  getrusage(RUSAGE_SELF,&usage);
    45   cpu_temp = usage.ru_utime.tv_sec;
     45  cpu_temp = (double)usage.ru_utime.tv_sec;
    4646  cpu_temp += 1.0e-6*((double) usage.ru_utime.tv_usec);
    4747#endif
     
    8787  // and assert that it is a clean model
    8888
    89   assert(!simplex.readMps(argv[1],""));
     89  if (argc <= 1) {
     90     printf("using %s <modelfile>\n", argv[0]);
     91     return 1;
     92  }
     93  int numMpsReadErrors = simplex.readMps(argv[1],"");
     94  if( numMpsReadErrors != 0 )
     95  {
     96     printf("%d errors reading MPS file\n", numMpsReadErrors);
     97     return numMpsReadErrors;
     98  }
    9099  time2 = cpuTime();
    91100  std::cout<<"Input took "<<time2-time1<<" seconds"<<std::endl;;
Note: See TracChangeset for help on using the changeset viewer.