Please write proper error messages, using for example
REQUIRE(cov.num_rows, "CStatistics::sample_from_gaussian(): Number of covariance rows must be positive!\n") and so on....