#!/bin/bash

. /etc/sysconfig/network/dhcp
: ${DHCLIENT_BIN:=dhcpcd}
if [ -x $DHCLIENT_BIN ]; then :
elif [ -x /sbin/$DHCLIENT_BIN ]; then DHCLIENT_BIN=/sbin/$DHCLIENT_BIN;
elif [ -x /sbin/dhclient ]; then DHCLIENT_BIN=/sbin/dhclient
fi
DHCLIENT=${DHCLIENT_BIN##*/}

for i in `pidof $DHCLIENT`; do 
	for device in `cat -A /proc/$i/cmdline`; do 
		device=${device%^@} 
		echo -e ${device##*^@} 
	done
done
exit 0
