וְהוּא־הִכָּה֩ אֶת־אִ֨ישׁ מִצְרִ֜י אשר [אִ֣ישׁ] מַרְאֶ֗ה וּבְיַ֤ד הַמִּצְרִי֙ חֲנִ֔ית וַיֵּ֥רֶד אֵלָ֖יו בַּשָּׁ֑בֶט וַיִּגְזֹ֤ל אֶֽת־הַחֲנִית֙ מִיַּ֣ד הַמִּצְרִ֔י וַיַּהַרְגֵ֖הוּ בַּחֲנִיתֽוֹ׃
También hirió él á un Egipcio, hombre de grande estatura: y tenía el Egipcio una lanza en su mano; mas descendió á él con un palo, y arrebató al Egipcio la lanza de la mano, y matólo con su propia lanza.
Haamek Davar
You shall not withhold the wages. If a person permissibly gained possession of someone else’s property, such as by a loan or the like, but he does not intend to return it is called עושק (oppression) and not גזל (stealing). Stealing is only is the case of, “And he grabbed (ויגזול) the spear from the hand of the Egyptian” (Shmuel II 23:21), which is that he forcibly grabbed it in the first place.
Rashbam
לא תגזול, similar to Samuel II 23,21 ויגזול את החנית מידו, “he wrenched the spear out of his hand.”
Ibn Ezra
robbed by force (as in, “he snatched the spear” [II Samuel 23:21])