Dogs and wolves bark for some of the same reasons.

Definitely. Dogs and wolves share barks that indicate alarm and intruders. Yet
dogs also seem to bark at times for no readily identifiable reason—researchers
don't know whether these barks are for communication or are for some other
unknown reason.