I have been running stock since I got the phone a year ago. Last week I finally decided to go for a custom rom and installed CM11 M9. All seemed well, except wifi, which would disconnect from network after being out of range (as normal), but then would't reconnect to any network. Only a reboot seemed to fix it, but only temporarily. It would quickly connect to the available known network, but if for some reason that connection was lost, it was unable to connect to any network at all.
I tried a couple of the latest nightlies, same problem. Then, a couple of days ago, I decided to try another rom, and went with Mahdi (which is based in CM).
Guess what, the problem remains! I found out that, sometimes, if I turn airplane mode on and off, it would be able to connect. But this isn't always the case.
I flashed that "non-hlos.bin wifi fix" thing, all happy because I was sure it would solve my problem, but to no avail. This is ridiculous... I don't know what else to do...
This is driving me crazy and I'm losing all hope. I'm starting to think that I'll have to go back to that dreaded Samsung stock rom... may somebody save me from that!