builtin/rm.c: consolidate error reporting for removing submodules
commit658ff473cf35217253aa956508ff0e42993711ad
authorJunio C Hamano <gitster@pobox.com>
Fri, 26 Jul 2013 06:05:17 +0000 (25 23:05 -0700)
committerJunio C Hamano <gitster@pobox.com>
Fri, 26 Jul 2013 06:05:17 +0000 (25 23:05 -0700)
treea46a6132123f8172c59d1519a7b86f64cc449dcf
parent914dc0289d1df75cfa744cea8ec84cb529cbc791
builtin/rm.c: consolidate error reporting for removing submodules

We have two (not identical) copies of error reporting when
attempting to remove submodules that have their repositories
embedded within them.  Add a helper function so that we do not have
to repeat similar error messages with subtly different wording
without a good reason.

Noticed by Jiang Xin.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin/rm.c