it seemed that one of the ships had been on an overnight run from barcelona to palma and the captain , who was dismissed soon afterwards , had missed the port and run straight into some cliffs on the island of cabrera , only a few nautical miles away .