[Libreoffice] Help here, I think I'm blinded

Kayo Hamid kayo.hamid at gekkolinux.com.br
Mon Feb 28 13:32:52 PST 2011


 Guys I have something that I see a lot and do not know way someone will 
 use it:

 //code
 static WinSalMenuItem* ImplGetSalMenuItem( HMENU hMenu, UINT nPos, BOOL 
 bByPosition=TRUE )
 {
     DWORD err=0;

     MENUITEMINFOW mi;
     memset(&mi, 0, sizeof(mi));
     mi.cbSize = sizeof( mi );
     mi.fMask = MIIM_DATA;
     if( !GetMenuItemInfoW( hMenu, nPos, bByPosition, &mi) )
         err = GetLastError();

     return (WinSalMenuItem *) mi.dwItemData;
 }
 //end

 'err' saves some values but who uses it? I see a lot of it on the code, 
 local variables with attribution, and no one inside the function uses, 
 and no one sends the variable for others externally.

 revol_


More information about the LibreOffice mailing list