One could extend that hypothesis to ask if there's a connection between English long and Yiddish schlong.
- English long ultimately derives from Proto-Indo-European *dlongʰos (“long”).
- Yiddish schlong is from German Schlange ("snake") and ultimately derives from Proto-Indo-European *slenk- (“to wind, twist, slink, creep”).
That is, no apparent connection.
Back to your particular thought:
- Japanese 長- naga- is thought to derive from, or be cognate with, obsolete verb 流る nagaru, root of modern verb pair 流れる nagareru ("to flow") / 流す nagasu ("to flush something, to make something flow"). I've also thought these might be related to verb 投ぐ nagu, modern 投げる nageru ("to throw").
- Sanskrit नाग naga ("snake") ultimately derives from Proto-Indo-European *sneg- (“to crawl; a creeping thing”), the same as English snake.
So again, no apparent connection.