Have I understood the loss function from the original U-Net paper correctly?
Yes, $E$ is the cross-entropy function and a direct generalization of the binary case.
For the binary case, probability to belong to the class $1$ is given by a sigmoid function $\sigma(x)$ of the output $x$, and the probability to belong to the class $0$ is $1 - \sigma(x)$.
Therefore the binary crossentropy will give:
$$
-\sum_i (l_i \log \sigma(x) + (1 - l_i)  \log (1 - \sigma(x))
$$
Where the sum is over all samples in the dataset. Because $l_i$ is a binary variable one of these two terms would be zero. The gradient descent forces the model to predict true label with more confidence.
For the multiclass case, now the output is a $K$-vector and the softmax function forces its elements to sum to one:
$$
\sum_{i = 1}^{K} p_i = 0
$$
The true label is one-hot encoded vector, with $1$ on the position of the true label, and $0$ elsewhere. The generalization of the binary case is:
$$
-\sum_i \sum_{j = 1}^{K}(l_{ij} \log \sigma_j(x) + (1 - l_{ij})  \log (1 - \sigma_j(x))
$$
In this case, there will be $K$ non-vanishing contributions.The minization of $E$ forces the classifier to predict the true label more confidently, and all other (to make $\log(1 - \sigma_j(x))$) as small  as possible.