rmdir.c revision 3f54fd611f536639ec30dd53c48e5ec1897cc7d9
ccb84c1cb43fb0ed70c5bf2d364e671820473ed5Francisc Nicolae Bungiu/***********************************************************************
734257b9ea9fcaa18d4e3627f54f5295a99aa1f7Felix Gabriel Mance* This software is part of the ast package *
ccb84c1cb43fb0ed70c5bf2d364e671820473ed5Francisc Nicolae Bungiu* Copyright (c) 1985-2011 AT&T Intellectual Property *
ccb84c1cb43fb0ed70c5bf2d364e671820473ed5Francisc Nicolae Bungiu* and is licensed under the *
ccb84c1cb43fb0ed70c5bf2d364e671820473ed5Francisc Nicolae Bungiu* Eclipse Public License, Version 1.0 *
ccb84c1cb43fb0ed70c5bf2d364e671820473ed5Francisc Nicolae Bungiu* by AT&T Intellectual Property *
ccb84c1cb43fb0ed70c5bf2d364e671820473ed5Francisc Nicolae Bungiu* A copy of the License is available at *
c038fcf2030a6cfac7a261dee48a9eb29edb78eaFelix Gabriel Mance* http://www.eclipse.org/org/documents/epl-v10.html *
ccb84c1cb43fb0ed70c5bf2d364e671820473ed5Francisc Nicolae Bungiu* (with md5 checksum b35adb5213ca9657e911e9befb180842) *
734257b9ea9fcaa18d4e3627f54f5295a99aa1f7Felix Gabriel Mance* Information and Software Systems Research *
c038fcf2030a6cfac7a261dee48a9eb29edb78eaFelix Gabriel Mance* AT&T Research *
c038fcf2030a6cfac7a261dee48a9eb29edb78eaFelix Gabriel Mance* Florham Park NJ *
ccb84c1cb43fb0ed70c5bf2d364e671820473ed5Francisc Nicolae Bungiu* Glenn Fowler <gsf@research.att.com> *
ccb84c1cb43fb0ed70c5bf2d364e671820473ed5Francisc Nicolae Bungiu* David Korn <dgk@research.att.com> *
ccb84c1cb43fb0ed70c5bf2d364e671820473ed5Francisc Nicolae Bungiu* Phong Vo <kpv@research.att.com> *
5180a08007989fd364622fc9bc01f82141643f7bFelix Gabriel Mance***********************************************************************/
31a5ba51cd6d24e28a23abf64ce4043a45eabbefFelix Gabriel Mance register int n;
734257b9ea9fcaa18d4e3627f54f5295a99aa1f7Felix Gabriel Mance static char* cmd[] = { "/bin/rmdir", "/usr/5bin/rmdir", 0 };
ccb84c1cb43fb0ed70c5bf2d364e671820473ed5Francisc Nicolae Bungiu if (stat(path, &st) < 0) return(-1);
31a5ba51cd6d24e28a23abf64ce4043a45eabbefFelix Gabriel Mance if (procclose(procopen(cmd[n], av, NiL, NiL, 0)) != -1)