  We investigate the effects of hadronic cascades on the gamma-ray burst (GRB)
prompt emission spectra in scenarios of efficient neutrino production. By
assuming a fiducial GRB spectrum and a power-law proton distribution extending
to ultra-high energies, we calculate the proton cooling rate and the neutrino
emission produced through photopion processes. For this, we employ a numerical
code that follows the formation of the hadronic cascade by taking into account
non-linear feedback effects, such as the evolution of the target photon field
itself due to the contribution of secondary particles. We show that in cases of
efficient proton cooling and subsequently efficient high-energy neutrino
production, the emission from the hadronic cascade distorts and may even
dominate the GRB spectrum. Taking this into account, we constrain the allowable
values of the ratio $\eta_p=L_p/L_{\gamma}$, where $L_{p}$ and $L_{\gamma}$ are
the isotropic equivalent proton and prompt gamma-ray luminosities. For the
highest value of $\eta_{p}$ that does not lead to the dominance of the
cascading emission, we then calculate the maximum neutrino luminosity from a
single burst and show that it ranges between $(0.01- 0.6)L_{p}$ and
$(0.5-1.4)L_{\gamma}$ for various parameter sets. We discuss possible
implications of other parameters, such as the magnetic field strength and the
shape of the initial gamma-ray spectrum, on our results. Finally, we compare
the upper limit on $\eta_p$ derived here with various studies in the field, and
we point out the necessity of a self-consistent treatment of the hadronic
emission in order to avoid erroneously high neutrino fluxes from GRB models.
