~ubuntu-branches/ubuntu/vivid/slurm-llnl/vivid

« back to all changes in this revision

Viewing changes to src/slurmd/common/setproctitle.c

  • Committer: Bazaar Package Importer
  • Author(s): Gennaro Oliva
  • Date: 2009-09-24 23:28:15 UTC
  • mfrom: (1.1.11 upstream) (3.2.4 sid)
  • Revision ID: james.westby@ubuntu.com-20090924232815-enh65jn32q1ebg07
Tags: 2.0.5-1
* New upstream release 
* Changed dependecy from lib-mysqlclient15 to lib-mysqlclient 
* Added Default-Start for runlevel 2 and 4 and $remote_fs requirement in
  init.d scripts (Closes: #541252)
* Postinst checks for wrong runlevels 2 and 4 links
* Upgraded to standard version 3.8.3
* Add lintian overrides for missing slurm-llnl-configurator.html in doc
  base registration
* modified postrm scripts to ignore pkill return value in order to avoid
  postrm failure when no slurm process is running
* Checking for slurmctld.pid before cancelling running and pending
  jobs during package removal 

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
/*****************************************************************************\
2
2
 * src/slurmd/common/setproctitle.c - argv manipulation 
3
 
 * $Id: setproctitle.c 13672 2008-03-19 23:10:58Z jette $
 
3
 * $Id: setproctitle.c 17276 2009-04-17 17:03:49Z jette $
4
4
 *****************************************************************************
5
 
 *  Copyright (C) 2002 The Regents of the University of California.
 
5
 *  Copyright (C) 2002-2007 The Regents of the University of California.
 
6
 *  Copyright (C) 2008-2009 Lawrence Livermore National Security.
6
7
 *  Produced at Lawrence Livermore National Laboratory (cf, DISCLAIMER).
7
8
 *  Written by Mark Grondona <mgrondona@llnl.gov>.
8
 
 *  LLNL-CODE-402394.
 
9
 *  CODE-OCEC-09-009. All rights reserved.
9
10
 *  
10
11
 *  This file is part of SLURM, a resource management program.
11
 
 *  For details, see <http://www.llnl.gov/linux/slurm/>.
 
12
 *  For details, see <https://computing.llnl.gov/linux/slurm/>.
 
13
 *  Please also read the included file: DISCLAIMER.
12
14
 *  
13
15
 *  SLURM is free software; you can redistribute it and/or modify it under
14
16
 *  the terms of the GNU General Public License as published by the Free
307
309
#endif /* PS_USE_CLOBBER_ARGV */
308
310
}
309
311
 
 
312
/* Free memory allocated by init_setproctitle.
 
313
 * Used to verify that all allocated memory gets freed */
 
314
void fini_setproctitle(void)
 
315
{
 
316
#if SETPROCTITLE_STRATEGY == PS_USE_CLOBBER_ARGV
 
317
        int i;
 
318
 
 
319
        for (i = 0; environ[i] != NULL; i++) {
 
320
                free(environ[i]);
 
321
        }
 
322
        free(environ);
 
323
        environ = (char **) NULL;
 
324
#endif /* PS_USE_CLOBBER_ARGV */
 
325
}
 
326