function [names, values] = appendLicenseEnvVars(names, values)
% Append to environment names and values if required (i.e. not licensed online).

% Copyright 2014 The MathWorks, Inc.

isLicensedOnline = parallel.internal.cluster.getOnlineLicenseInfo();
if ~isLicensedOnline
    names = [reshape(names, 1, []), {'MW_LICENSE_OVERRIDE'}];
    values = [reshape(values, 1, []), {feature('lmsearchpath')}];
end
end
