  For $1$-periodic functions $f$ satisfying only a weak local regularity
assumption of Dini's type at rational points of $]0,1[$, we study the Farey
sums
  $$F_n(f)= \sum_{\frac{\k}{\l}\in \F_n} f\big(\frac{\k}{\l}\big),\qq
F_{n,\s}(f)= \sum_{\frac{\k}{\l}\in \F_n}
\frac{1}{\k^\s\l^\s}f\big(\frac{\k}{\l}\big),\qq 1/2\le \s<1 , $$ where $\F_n$
is the Farey series of order $n\ge 1$. We obtain sharp estimates of
$F_{n,\s}(f)$, for all $0< \s\le1$. We prove similar results for the
corresponding Riemann quadratic sums $$ S_{n,\s}(f) \ =\ \sum_{1\le k\le \ell
\le n}\frac{1}{(k\ell)^{\s }}\, f\big( \frac{k}{\ell}\big). $$ These sums are
related to local integrals of the Riemann zeta-function over bounded intervals
$I$, which are considered in the last part of the paper.
