Yes, it's safe. That's just a cable
Details:
- 2DS & 3DS official chargers are providing 4.6V / 0.9A.
- USB devices (Chargers, PC...) are providing 5V which is within operational tolerance.
Be aware that certain USB2.0 devices are only supplying 0.5A, which could make your console charge a bit slower. USB3.0 minimum amperage would be 0.9A. Do not be afraid to use a charger supplying more amps, your console will use what's needed.