diff options
| author | Markus Mittendrein <git@maxmitti.tk> | 2019-09-08 18:44:29 +0200 |
|---|---|---|
| committer | Markus Mittendrein <git@maxmitti.tk> | 2019-09-08 18:44:29 +0200 |
| commit | a5ceb18e2b87c4547d78e17c832948f589ac35da (patch) | |
| tree | b754a35c61e466c685404e00b81cbfed04ea0369 /examples | |
| parent | ceb94a5ba7c9a0742a51cc01c861cb5091963a17 (diff) | |
| download | cc4group-a5ceb18e2b87c4547d78e17c832948f589ac35da.tar.gz cc4group-a5ceb18e2b87c4547d78e17c832948f589ac35da.zip | |
Allow the maker to be set by the environment variable CC4GROUP_MAKER for c4copy
Diffstat (limited to 'examples')
| -rw-r--r-- | examples/c4copy.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/examples/c4copy.c b/examples/c4copy.c index 3c0d092..30cf95c 100644 --- a/examples/c4copy.c +++ b/examples/c4copy.c @@ -23,6 +23,16 @@ int main(int argc, char* argv[]) } else { + char* maker = getenv("CC4GROUP_MAKER"); + if(maker != NULL) + { + if(!cc4group.setMaker(group, maker, NULL, true)) + { + fprintf(stderr, "WARNING: Could not set maker: %s\n", cc4group.getErrorMessage(group)); + } + } + + success = cc4group.save(group, argv[2]); if(!success) |
