Usually what happens is they target facilities where known terrorists organizations are, and unfortunately Intel does not have a scope about the people inside, and civilian casualties do occur.
I'm not saying it's right or wrong but it happens, and it's unfortunate.