use struct cmd_priv