Source and destination arguments to strncpy were swapped. This mistake was made in the conversion of bcopy() to strncpy().