MCPcopy Create free account
hub / github.com/LASzip/LASzip / make_unzipper

Function make_unzipper

example/laszippertest.cpp:287–306  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

285//---------------------------------------------------------------------------
286
287static LASunzipper* make_unzipper(IStream* ist, const LASzip* laszip)
288{
289 LASunzipper* unzipper = new LASunzipper();
290 if (unzipper == 0)
291 {
292 log("ERROR: could not alloc lasunzipper\n");
293 exit(1);
294 }
295 bool success;
296 if (ist->m_use_iostream)
297 success = unzipper->open(*ist->streami, laszip);
298 else
299 success = unzipper->open(ist->ifile, laszip);
300 if (!success)
301 {
302 log("ERROR: could not open laszipper with %s because %s\n", ist->m_filename, unzipper->get_error());
303 exit(1);
304 }
305 return unzipper;
306}
307
308//---------------------------------------------------------------------------
309

Callers 1

run_testFunction · 0.85

Calls 3

logFunction · 0.85
openMethod · 0.45
get_errorMethod · 0.45

Tested by

no test coverage detected