Aces High Bulletin Board

General Forums => The O' Club => Topic started by: straffo on October 13, 2005, 09:02:48 AM

Title: Code hell !
Post by: straffo on October 13, 2005, 09:02:48 AM
Here id is a string converted to long then casted to void *
Then this method is called  :

void FenI_DCAT_02_17::cbClickRna(void* fenetre, void* controle, void* Id)
{
   long * pTemp = (long*) Id ;Ok cast to long ... I can understand
   pCast(fenetre)->clickerRna((void*) pTemp[0]);  wtf ??? note we pass the value , not the @
}

Let see clickerRna now ...

void FenI_DCAT_02_17::clickerRna(void* Id)
{
   CWaitCursor sablier;

   long num = (long) Id; wtf  cast to long again... ?
   m_pAppli->restituerNotice(m_pOeRC, num);

}
Guess what in restituerNotice the parameter num is converted to ... string !!

It's the magic roundabout !
Title: Code hell !
Post by: AKS\/\/ulfe on October 13, 2005, 09:06:10 AM
Is that the code that renames French fries to Freedom fries?
-SW
Title: Code hell !
Post by: deSelys on October 13, 2005, 09:10:41 AM
HHHHHUUUUUUUUUuuuuuuuuuuuuuuu uuuuuuuuuuuuuuuuuuuuuuuuuuhhh hh???:huh
Title: Code hell !
Post by: straffo on October 13, 2005, 09:35:11 AM
And now for something not really different !

une autre pour la route !

Booleen z_bGriser (FAUX);

   // verification qu'une notice est memorisee
   if (BnfSession::instance()->noticeMemorisee()->nature() != BnfNoticeMemorisee::aucun)
   {
      z_bGriser = VRAI;
   }
   else
   {
      z_bGriser = FAUX;
      return z_bGriser;
   }

   // verification que la notice memorisee est une notice bibliographique
   BnfNoticeMemorisee::NatureNotice z_txtNature = BnfSession::instance()->noticeMemorisee()->nature();
    if (z_txtNature == BnfNoticeMemorisee::autorite)
   {
      z_bGriser *= VRAI; 0 * 1 = 0 no ? wtf is this !
   }
   else
   {
      z_bGriser = FAUX;
      return z_bGriser;
   }
Title: Code hell !
Post by: deSelys on October 13, 2005, 09:43:52 AM
Is this VisualVoodoo 7.2?
Title: Code hell !
Post by: straffo on October 13, 2005, 09:49:45 AM
Nope it's : we are lucky it work !

( a million € project !)
Title: Code hell !
Post by: T0J0 on October 13, 2005, 12:26:16 PM
Thats the statement that calculates and rounds the euro transactions on iraqii oil for food profits and dumps it in a swiss bank account?

TJ
Title: Code hell !
Post by: DREDIOCK on October 13, 2005, 05:43:18 PM
Quote
Originally posted by T0J0
Thats the statement that calculates and rounds the euro transactions on iraqii oil for food profits and dumps it in a swiss bank account?

TJ
:rofl
Title: Code hell !
Post by: Saintaw on October 14, 2005, 01:05:51 AM
Straffo, add a division by zero in there, just to make it fun :D
Title: Code hell !
Post by: AKKarma on October 14, 2005, 10:37:09 AM
Quote
Originally posted by straffo
// verification que la notice memorisee est une notice bibliographique

I have no idea what this comment says, but I just pasted it into the C# module that I'm working on.  :aok
Title: Code hell !
Post by: straffo on October 14, 2005, 01:37:20 PM
:lol

I'm working on a software for archivists ,exactly I'm working on the catalogue part

The part which generate this kind of mess (http://catalogue.bl.uk/F/UIH5FJB2R6PVHK9R5SNQXCUQCTGVUNMBGF6FU52QKFX67C6IQT-01873?func=full-set-set&set_number=092945&set_entry=000009&format=001)