Mistři v programování na #hovnokod

C/C++ #1076

Jak prevadeji byte order v Indii... (odstrasujici priklad outsourcingu) Bonus: jestlipak najdete zaludnou chybicku?

long value =0L;

#ifdef __LINUX__
  value |= (long)tmp[0];
  value |= (long)tmp[1];
  value |= (long)tmp[2];
  value |= (long)tmp[3];
#else
  value = *((long *)tmp) ;
#endif

return value;

Miroslav Mikuš,