usr.bin/mail/cmd1.c
/*
 * List the folders the user currently has.
 */
List the folders the user currently has.
List the folders the user currently has .
int
folders()
{
	char dirname[BUFSIZ];
	char *cmd;
	if (getfold(dirname) < 0) {
		printf("No value set for \"folder\"\n");
		return 1;
	}
	if ((cmd = value("LISTER")) == NOSTR)
		cmd = "ls";
	(void) run_command(cmd, 0, -1, -1, dirname, NOSTR, NOSTR);
	return 0;
}
int folders ( ) { char dirname [ BUFSIZ ] ; char * cmd ; if ( getfold ( dirname ) < 0 ) { printf ( " \" \" \n " ) ; return 1 ; } if ( ( cmd = value ( " " ) ) == NOSTR ) cmd = " " ; ( void ) run_command ( cmd , 0 , -1 , -1 , dirname , NOSTR , NOSTR ) ; return 0 ; }
List the folders the user currently has.
List the folders the user currently has .