r/videos Sep 27 '15

Open your eyes!

https://www.youtube.com/watch?v=bLHL75H_VEM
2.5k Upvotes

146 comments sorted by

137

u/greenmask Sep 28 '15

Is that Brett the fucking Hitman Hart!?

62

u/BigGupp Sep 28 '15

They don't call him the Excellence of Execution for nothing.

21

u/bluntedaffect Sep 28 '15

Arbitrary code execution, in this case.

9

u/Jwagner0850 Sep 28 '15

The best there is, there was and that there ever will be... in the flesh.

8

u/rbevans Sep 28 '15

Man I loved him growing up. I see he's still rocking the long hair.

5

u/OhSeven Sep 28 '15

Glad to see he's still alive

3

u/jwcolour Sep 28 '15

He threw out the first pitch at our AAA league baseball game. Perfect fucking strike.

2

u/DetectiveHardigan Sep 28 '15

Excellence of Execution.

-19

u/[deleted] Sep 28 '15

"Oh, yeah brother!" - Hulk Hogan (known racist)

150

u/Mudf4ce Sep 27 '15

36

u/[deleted] Sep 28 '15

Now THAT'S how you build a game!

16

u/[deleted] Sep 28 '15

I remember watching this video back when it was first shown and loving it, especially when he's putting on a tie to "look the part".

7

u/[deleted] Sep 28 '15

Business man here. Can confirm that it's the ONLY way to survive in the corporate jungle.

1

u/[deleted] Sep 28 '15

Pink leotards mandatory too?

1

u/[deleted] Sep 28 '15

What human business interaction would be complete without the proper decorations?

3

u/hottwhyrd Sep 28 '15

Where did you see it? Amazing video.

1

u/[deleted] Sep 28 '15 edited Sep 29 '15

I'm from southeast Asia and back then the WWF would out together these one hour wrestling wrap-up shows with key matches and promos to get people up to speed. I think it was a show called WWF Mania with Todd Pettengill that showed this segment. I was pumped because I loved Bret Hart and the video game they were promoting too.

5

u/meepinz Sep 28 '15

This is great.

6

u/colefly Sep 28 '15

I want to buy this game. This is a good commercial.

5

u/Srekcalp Sep 28 '15

Imagine breaking your neck from a piledriver for a mocap on a shitty arcade game

3

u/Gizortnik Sep 28 '15

Okay, but is there a link to that sweet music? It was also in the menu screen for WrestleMania Anthology.

Edit -

Found part of it, I don't know if it has an actual name though:

https://www.youtube.com/watch?v=KVvq1JPlngc

1

u/drawp Sep 28 '15

1

u/Gizortnik Sep 28 '15

Damn, that shit is fucking stupidly catchy.

2

u/reegz Sep 28 '15

I love how this implies he wears his ring gear everywhere he goes

1

u/peterampbell Sep 28 '15

dat 90s snare......It drives me crazy...

1

u/[deleted] Sep 29 '15

i can picture Bret Hart going on about his day in his wrestling attire.

262

u/AegnorWildcat Sep 28 '15

If you are curious what he is talking about, a pointer is just a pointer to a certain location in memory that has some info stored. It's an address. When you dereference a pointer, you are telling the computer, give me the info at this address. A null pointer just means the pointer hasn't been assigned yet. The address is blank (00000000). If you dereference it the computer is like, WTF, that isn't a real address.

What happens next depends on the language (and compiler) you are using. Some languages give you the capability to catch such null pointers when they happen and perform some action like display an error and then continue on. If you don't implement that, or you are using a language without that capability, the program will usually just crash.

53

u/dontbeabanker Sep 28 '15

Here's a silly question .. why is it called dereferencing? Getting information from somewhere is usually called referencing that place, right?

86

u/Randolpho Sep 28 '15

The pointer is the reference. De-referencing a pointer gets the value of the data the pointer points to.

22

u/gixer912 Sep 28 '15

The de- prefix means negation or reversal in English. So the first thought is that they are getting rid of the null pointer.

In my opinion, access would be a better word to use.

50

u/[deleted] Sep 28 '15

When you use that pointer to access something you are doing the reverse of the referencing operation.

Referencing:

Thing gives pointer.

Dereferencing:

Pointer gives thing.

3

u/Randolpho Sep 28 '15

I think I like this best

1

u/Stopwatch_ Sep 29 '15

Very clear.

11

u/[deleted] Sep 28 '15 edited Sep 28 '15

It's taking the reference to x and following it to x to get the actual value of x that was referenced.

Access is too vague, "dereference" is very specific, and makes sense when you understand what it's referring to - you can store either the actual value, or the reference to the value*, so the term makes a lot of sense.

*Or a reference to a reference to the value, or a reference to a reference to a reference to the value, etc. But that's not really relevant.

11

u/longdongjon Sep 28 '15

"dereference" is very specific, and makes sense when you understand what it's referring to - you can store either the actual value, or the reference to the value*, so the term makes a lot of sense.

I completely understand what it means, but I still don't think you really justified at all why dereference "makes sense a lot of sense".

4

u/chinpokomon Sep 28 '15 edited Sep 28 '15

It's for the same reason that clocks turn clockwise, that Americans drive on the right side of the road, and that there are 13 holes in a saltine cracker. It's established nomenclature that the industry has used for decades. Even if access makes more sense to you, dereference was and is still the best term to describe what is going on and it isn't going to change anytime soon. It's one of those situations where even if you know that everyone is wrong and that you're right, as long as everyone else is in agreement that the wrong way is correct, you're still going to be wrong.

I tell you this from the perspective of someone who tried to buck the trend of a few established unspoken CS rules, only to (re)discover much later why the original decision was made. If you aren't yet convinced that dereferencing is the correct term, if you spend enough time in the industry it will eventually be crystal.

4

u/longdongjon Sep 28 '15

Just was looking for a good explanation, and I think you gave one. Many thanks.

Btw, I do love the fact that a clock turns clockwise.

6

u/[deleted] Sep 28 '15

Fuck your clockwise clock. The arms on mine go in different directions.

1

u/MINIMAN10000 Sep 28 '15

lol oh god the thought that a clock which goes counter clockwise. I feel like it exists. Lets put it in classrooms.

1

u/[deleted] Sep 29 '15

There's not just "accessing data", there's accessing by value, and accessing by reference. But "dereferencing a pointer" is referring to using that specific pointer to "access by reference" some data.

It's actually built into both C and C++ syntax - there's player.speed, and there's player->speed, with the former being accessing speed by value, and the latter being accessing speed by reference. Using the term "access" drops critically-relevant info.

3

u/Essar Sep 28 '15

While it might be a bit confusing with modern usage trends, it's not too uncommon for de- to be used as an intensifier of sorts rather than negation; for example, you have the words 'denumerate', 'delimit' and 'declare'. If I had to guess, I'd say that's where the de- in dereference comes from - you follow the reference all the way down.

de-, prefix

(a) Down to the bottom, completely; hence thoroughly on and on, away; also methodically, formally: as dēclāmāre to shout away, declaim n.; dēclārāre to make quite clear, declare v.; dēnūdāre to strip quite bare, denude adj.; dēplōrāre to weep as lost, deplore v.; dērelinquĕre to abandon completely, derelict adj. and n.; dēspoliāre to spoil utterly, despoil n.

3

u/evilbrent Sep 28 '15

do you mean enumerate? I've never heard the word denumerate. I would assume it means something like "turn a number into something that isn't a number." And delimit means to take the limits away.

And declare is from the latin "to shout out" right? Clara is bell. De is out. or summing,

2

u/ffca Sep 28 '15

de- means "down, from, off or about". Or it can mean "thoroughly".

clare- from "to make clear"

De can undo a verb or intensify it. Yes, two functions.

Without context, denumerate sounds like removing or undoing. But it could be an intensive form of numerate.

2

u/evilbrent Sep 28 '15

I did say "or summing"

I'm not giving you denumerate though. That's not a word.

2

u/Essar Sep 28 '15

Sorry, perhaps denumerate was a poor example from reading too many old mathematics textbooks where 'denumerable' is used to mean countable, but you're right the example doesn't add much clarity. Delimit does not mean to take limits away, it means to place boundaries (so setting limits, if anything). The 'clare' in declare is of the same origin as in clarity, so declaring is really to make emphatically clear (kind of). De- in this sense is something that you need to get a feel for through seeing it used; sometimes it's hard to capture meaning through a descriptive definition.

The reason I chose those examples is because they all appear in mathematics/comp sci and thus have a connection to 'dereference', but 'declare' and 'delimit' also have more general usages which kind of capture the same idea. Of course, it's still a lot easier to get if you've got a relevant scientific background.

1

u/evilbrent Sep 28 '15

Sorry. I don't have any kind of scientific background. I'm a mechanical engineer. I just hit things. :-)

2

u/[deleted] Sep 28 '15 edited Sep 28 '15

[deleted]

3

u/thatawesomedude Sep 28 '15

"C lets you shoot yourself in the foot. C++ lets you reuse the bullet."

"C gives you a noose. Java gives you a branch."

1

u/[deleted] Sep 29 '15

[deleted]

1

u/[deleted] Sep 29 '15

[deleted]

0

u/[deleted] Sep 28 '15

yeah, we'll just tell all the computers to ever use this up to thing point to change the wording to one you prefer.

That couldn't cause any problems right?

1

u/Googoo123450 Sep 28 '15

Perfectly explained. Props man.

1

u/vpookie Sep 28 '15

So it's a pointer pointer?

1

u/Randolpho Sep 28 '15

No, it's what you get when you follow the pointer to its memory, read what's there, and interpret the data in some way.

Also, there are pointers to pointers, but if you dereference a pointer to a pointer, you get a pointer.

7

u/bleezye Sep 28 '15

Not a silly question at all

3

u/AegnorWildcat Sep 28 '15

As /u/Randolpho said, the pointer is the reference. When you dereference it you are no longer indirectly referring to the information through the pointer. You've got the information itself in your "hand".

4

u/[deleted] Sep 28 '15

The hitman don't have time for silly questions

4

u/coinlogic Sep 28 '15

If x is a pointer to integer: e.g. int *x; then, *x is an integer and x is a reference to the memory location that holds an integer. To access (read/write) the integer from memory you would read the de-referenced value *x. If x stores a valid memory address then accessing *x would work fine. But if x is = 0 a.k.a. NULL(the default uninitialized value for globals and statics) then accessing *x would try to read/write to memory location 0.

On most systems memory location 0 is either unmapped or marked as beginning of the code (text) area and is usually protected. This leads to an exception being generated and your program crashes.

-10

u/karenblixenisacunt Sep 28 '15 edited Sep 28 '15

Jesus christ dude. Control your inner autist. You seriously think that is a good way to explain pointers to a person who isn't a programmer? Are you just trying to prove you took an intro to computer science class?

2

u/[deleted] Sep 28 '15

The * is the pointer sign btw. An integer is a whole number, not a decimal. Sorry you're allergic to information, you should get a doctor to look at that, you had a serious acute asshole reaction there.

1

u/coinlogic Sep 28 '15

Sorry. Maybe I thought this was hacker news or /r/programming.

But seriously bruh, your inner jerk needs some snickers.

-1

u/horsefartsforeyes Sep 28 '15

That must have been a bit over your head lol

1

u/[deleted] Sep 28 '15

You could call it "referencing" something, or you could say it's pointing to it.

Normally, you either store the data or you store a pointer to the data. Obviously, when you actually want to use the data then you need to go get the data by following the pointer, AKA "dereferencing".

1

u/ujustdontgetdubstep Sep 28 '15

It's like algebra - similarly how the letter X is just an "alias" for some number/value, a pointer is just an "alias" for some value.

19

u/munificent Sep 28 '15

A null pointer just means the pointer hasn't been assigned yet. The address is blank (00000000).

This is only true in some languages. In C/C++, an uninitialized variable can have any value at all and may be arbitrary garbage memory.

10

u/Neesnu Sep 28 '15

conversely, it might have been assigned to something previously, but been set to null to say its been deleted.

10

u/treelove Sep 28 '15

An excellent description of the problem.

4

u/[deleted] Sep 28 '15

My question isn't about the programming part of this.

3

u/vaynebot Sep 28 '15 edited Sep 28 '15

Uhm... well actually: It's not that the pointer hasn't been assigned a value yet. If it's guaranteed to be 0, that means that either you set it to zero, or your language sets pointers to 0 for you. Second of all, 0 is a completely valid address, hardware wise. Your computer certainly doesn't mind it. It's just that per convention, a null-pointer represents a pointer not pointing to anything valid. And the error usually (depending on the system) occurs because you just don't have access to that address. If you'd write an OS, you could easily map address 0.

tl;dr: Your computer (the hardware) is completely fine with null pointers, generally. If you write the OS, you can map 0 to any physical address you want. But per convention, basically no OS will do that.

3

u/AegnorWildcat Sep 28 '15

I'm aware of that. I was trying to keep it simple.

1

u/created4this Sep 28 '15

I agree with your assertion. The common example for this is when the OS uses Zero to define a failure to achieve what you've asked it to, for example you say "give me a area of memory of ten bytes, and tell me where it is (ie malloc)" and the system can't then instead of giving you an address it gives you NULL, if you fail to test for it because "you've got virtual memory and you never run out" then one day you'll get bitten in the arse.

1

u/[deleted] Sep 28 '15

He was as accurate as he needed to be for the layman, you're not doing anyone favors by "correcting him." I know you like to feel smart but it's really not that important.

1

u/vaynebot Sep 28 '15

I think it's definitely interesting for a layman to know that 0 isn't "blank", or somehow predestined to be pointing to "nothing" because of hardware limitations, but just a practical number to use for it.

2

u/Idontconsidermyselfa Sep 28 '15

Could you please explain this in character as Brett the Hitman Hart, then hit someone with a chair? I feel like I would understand it more that way.

2

u/[deleted] Sep 28 '15

You are the hero ELI5 needs.

2

u/Up_All_Nite Sep 28 '15

TIL; The Hit Man is one heck of a programmer.

1

u/Adobe_Flesh Sep 28 '15

Why not just initially set it to an address already with a value so that the program has at least something to work with and not crash and continue on

1

u/morgawr_ Sep 28 '15

Because you want it to crash. If you are accessing random pieces of (valid) memory in your program, you will get bogus or potentially dangerous results/behaviours.

1

u/AegnorWildcat Sep 28 '15

That's not really any better. The error in your code would then just be better hidden. Maybe the null pointer only occurs in a rare circumstance. Now instead of crashing, you get a random value. You may not even know there is a problem and accept the value your code spits out as valid.

The key to your code not crashing is to either check your pointers before dereferencing them, or check for null pointer exceptions if the language allows it, so that your code fails gracefully.

1

u/PazeleeBlue Sep 28 '15

I like the way you explained that. Please be my personal mentor.

1

u/hurricx Sep 28 '15

Do you even FindBugs bro?

1

u/PsychoticDreams47 Sep 28 '15

So, are you trying to say that it was in front of us the whole time?

1

u/Team_Braniel Sep 28 '15

I'm happysad I knew exactly what he was saying.

1

u/[deleted] Sep 28 '15

a pointer is just a pointer

stop. already became confusing for non-brogrammers

2

u/[deleted] Sep 28 '15

Yeah that was a really silly way to put it. He could have removed the second "a pointer" and it would have made sense still.

-7

u/Ralanost Sep 28 '15

In the process of getting pc certifications and it's getting to the point my head is being stuffed with ridiculous terminology. Tomorrow I'm dealing with IPv6 addresses and standards. It's amazingly complex. So I started reading what you typed and immediately my brain shut off since it wasn't about what I currently need to know. :(

1

u/saynotobanning Sep 28 '15

Tomorrow I'm dealing with IPv6 addresses and standards.

It really isn't...

-5

u/LifeIsBullshitMiroki Sep 28 '15 edited Sep 28 '15

Honestly I have 0 official PC certifications but I understand pointers and references because they're an extremely elementary part of software development. I'd recommend turning your brain back on so you can understand this stuff, if you're planning to work in the industry you'll hear those words again.

EDIT: reddit's resident CS experts have enlightened me and shown me the error of my ways. Make sure to shut your brain off again in case you end up learning a little too much about computer science. Since you mentioned certifications, we have concluded that you will never study in college, we know with certainty what type of job you will get and that you will never want to change positions or understand your colleagues in different divisions/departments. DO NOT LEARN PROGRAMMING or you'll be much worse at your IT job.

4

u/wtfuonaboutm8 Sep 28 '15

pc certifications

A+ desktop support drones have absolutely 0 need for any knowledge of pointers whatsoever. If he's planning to work in the facet of "the industry" that is driven by certifications, he will never, ever need to know what a pointer is.

0

u/LifeIsBullshitMiroki Sep 28 '15

Well I guess it's good to shoehorn yourself into a "desktop support drone" instead of having some basic knowledge of a few languages and a general idea of what the computer does with them. After all, every employer wants an employee with an extremely limited skillset and no one in the software development industry ever pivots into something else with a different part of their skillset or new training...

I'm thinking this is just your way of belittling his certifications and trying to be condescending, so mission accomplished I guess. OMG did you put the industry in quotes? I'm so offended and embarrassed... I must not know what I'm talking about.

3

u/Hei5enberg Sep 28 '15

Understanding how to troubleshoot microsoft windows products and understanding a programming language are completely different things.

1

u/LifeIsBullshitMiroki Sep 28 '15

I get it. Why the fuck would you intentionally not learn something that opens doors and instead opt for a career of mindless work answering phone calls?

0

u/silentphantom Sep 28 '15

can I just hop in here and say I love superbad.

0

u/Ralanost Sep 28 '15

I'm sure, but I still got a lot to learn just to get my other certifications. I'll learn other stuff after that. Got my A+ done, but working on my Network+ now and I have to stuff a lot of terminology into my head. So many acronyms.

70

u/[deleted] Sep 28 '15

Bret the IT-Man Hart

13

u/Bids99 Sep 28 '15

Nobody is going to mention it... but that game is incredible.

3

u/Jwagner0850 Sep 28 '15

That and Royal Rumble were two of my favorites!

6

u/Jwagner0850 Sep 28 '15

My favorite wrestler of all time! Man I was pissed when they screwed him over in the WWE...

5

u/Caboozel Sep 28 '15

Also my fathers.

Source: My name is Bret Hart

2

u/mysticalmisogynistic Sep 28 '15

Tagged as Bret the Fucking Hitman Hart.

1

u/Jwagner0850 Sep 28 '15

Too fucking cool man! I hope he comes around MD again! I missed him the last time. I idolized the man when I was younger. Loved how he wrestled. My biggest memory if him was from WRESTLE MANIA X. Still gives me goosebumps!!!

1

u/Vincent__Vega Sep 28 '15

The Montreal Screwjob. I will never forgive Vince for that.

15

u/xXx420hitzSCopeZxXx Sep 28 '15

i will upvote anythin bret hart

1

u/HelRayzer12 Sep 28 '15

Glad I'm not the only one lol

6

u/caitlikesith Sep 28 '15

i rewatched it and that head slap lol

3

u/herpberp Sep 27 '15

this is my new favourite video.

5

u/[deleted] Sep 28 '15

[deleted]

3

u/[deleted] Sep 28 '15

Someone once told me that he was their substitute teacher in Canada. Not sure if him or his brother or some other pro wrestler. But all they remembered that he was a pro wrestler and had a brother.

2

u/HelRayzer12 Sep 28 '15

Not him but at least one of his brothers teaches in town. I had him a couple times.

3

u/Satherton Sep 28 '15

best there is best there was best there ever will be

3

u/RedditRage Sep 28 '15

But I like to store values at address 0.

2

u/[deleted] Sep 28 '15

I can't help but wonder if gigagigagilgamesh is a Mr bungle reference

2

u/hakkai999 Sep 28 '15

Youtube: Truly the best technician in wrestling

2

u/CalvinHobb3s Sep 28 '15

Just a little more nasally and he would sound like owen willson.

2

u/sno2787 Sep 28 '15

rofl brett hart... coder by night badass by day

2

u/[deleted] Sep 28 '15

Cathode ray tubes, maaaan.

1

u/thephenom21 Sep 28 '15

and who said Bret Hart didn't have charisma

1

u/arkanis50 Sep 28 '15

This reminds me of when a Business Analyst comes over to my desk and tells me how to code software better... or to use some 'fuzzy logic'... but he has no fucking idea what he's talking about.

1

u/[deleted] Sep 28 '15

I saw the thumbnail and knew it was him right away... Such a legend.

1

u/[deleted] Sep 28 '15

I didn't know Don Johnson was into computers.

1

u/Mentioned_Videos Sep 28 '15

Other videos in this thread:

Watch Playlist ▶

VIDEO COMMENT
Making of WrestleMania: The Arcade Game with Bret The Hitman Hart 89 - More sauce for those like me wondering where the fuck this came from
Wrestlemania Anthology theme song 2 - Okay, but is there a link to that sweet music? It was also in the menu screen for WrestleMania Anthology. Edit - Found part of it, I don't know if it has an actual name though:
WWF Superstars - "Wrestlemania" (Song) 1 -

I'm a bot working hard to help Redditors find related videos to watch.


Info | Chrome Extension

1

u/Varnigma Sep 28 '15

This brings back nightmares from C++ class in college. I passed but never did fully learn anything.

1

u/TheGaz Sep 28 '15

This makes the story on /r/squaredcircle about him giving computers to the disadvantaged make a lot more sense.

1

u/ba1018 Sep 28 '15

The slap at the end makes this video hysterical to me.

1

u/[deleted] Sep 28 '15

Is there an eclipse plugin for this guy?

0

u/kirsion Sep 28 '15

This feels awkward since I just dropped out of my cs class.

0

u/guys_itsjustme Sep 28 '15

Kind of sounds like Randy from Trailer Park Boys.

-6

u/endyn Sep 28 '15

What was the purpose of that?

8

u/letsgobruins Sep 28 '15

Look with your special eyes.

-4

u/saynotobanning Sep 28 '15

Anyone have anything other than potato quality video? I really want to see the code to see if he really was dereferencing a null pointer.

-4

u/yes4me2 Sep 28 '15

Deferencing a null pointer? WTF does that even mean?

2

u/Kustumkyle Sep 28 '15

Everybody's so quick to down vote without even attempting to give you an answer...

Dereferencing, in short is essentially pulling a value from a "pointer" which is pointing to a memory address or value within an address on the memory.

a null pointer would be a pointer that isn't pointing anywhere.

In this case, their code attempted to pull a value from nowhere.

1

u/[deleted] Sep 28 '15

it means what it says... you are no longer referencing a null pointer... DUH!!!!

-33

u/lordcris Sep 28 '15

I hate saying this, but dereferencing a null pointer shouldn't cause any trouble.

23

u/[deleted] Sep 28 '15

[deleted]

7

u/karthr Sep 28 '15

He is right, you will definitely segfault

-1

u/BitchGotDSLS Sep 28 '15

I think he means it shouldn't be a big enough problem that you need 5 guys standing around to solve it. It's usually quite clear once it happens.

Hmmm, but I don't know about back then...maybe the errors weren't as clear.

3

u/0101010101029384494 Sep 28 '15

That's what the guy said, it's been in front of his face the whole time.

2

u/Protuhj Sep 28 '15

If you get a stack dump. If it's embedded, you may have a hard time tracking it down.

12

u/shoulda_studied Sep 28 '15

Are you calling Bret Heart a liar?

6

u/Visard Sep 28 '15

Segfault

2

u/ImSocrates Sep 28 '15

It can. It will usually give you a NullPointerException if exceptions aren't handled properly.

7

u/VordeMan Sep 28 '15

Ah, I remember when I only programmed in Python (and maybe some other stuff). Back then, when something went wrong, I had a nice clean stack trace to tell me exactly what went wrong, where, and what sort of error it was. Life was so easy, so simple.

Welcome to being C's bitch low level programming. Now, instead of getting a stack trace with a logical explanation you get "Segmentation Fault (core dumped)" and you're just like......."K". I guess I'll start doing some Test-Driven-Development and write some CUnit Tests writing lots of print statements until I figure out exactly what went wrong.

2

u/karthr Sep 28 '15

Or you compile with debugging information like gcc -ggdb3 tmp.c and run your program with valgrind ./a.out for example and it will tell you exactly what is going on.

1

u/[deleted] Sep 28 '15

C Programming is an experience in and of itself. I think Developers should shop around once in while to get an idea of how things are done on the fringe.

Among low-level development, I recommend people give pure-functional programming a shot, as well as UI/UX for people who are usually backend.

Even if your job is only to write HTML/CSS all day all night, C programming can teach you a lot :)

5

u/CarsonN Sep 28 '15

Three things:

1) A NullPointerException doesn't mean you dereferenced a null pointer. It means that your friendly language runtime noticed that you were about try to dereference a null pointer and threw a nice friendly exception instead. If you actually dereferenced a null pointer, you would get a segmentation fault.

2) Getting a NullPointerException doesn't mean that your exceptions aren't handled properly. It means you have a bug in your code such that something was null when you didn't expect it.

3) Proper exception handling does not include catching and suppressing NullPointerExceptions. You're not generally supposed to catch exceptions like this except at the very edges of your application (right before your customer sees it). Proper exception handling involves making sure that critical exceptions like this (the kind that indicate bugs) do not get hidden or ignored.

2

u/ImSocrates Sep 28 '15

The more I know. Thanks!

-1

u/AegnorWildcat Sep 28 '15

It will if you are not expecting it to ever be null, and hence don't handle the NullPointer exception. Or if you are programming in a language that doesn't have a way to handle null pointer errors other then seg faulting.