C importance.

18 February 2009 at 9:58 am 3 comments

During last months I had experience in C teaching. Many students told me that C is not important : in their opinion it is obsolete, useless, less attractive than other object oriented languages (someone included VisualBasic 6 also :-)). Well this morning my Linux Box alerted me with new updates included security option for “sudo” command. I gave a look to the description of the problem and this is the code updated (if you have some C basics you shoudn’t have difficutl in reading and understanding it) :

static int command_matches_dir __P((char *, size_t));
@@ -651,9 +651,11 @@ usergr_matches(group, user, pw)
      * If the user has a supplementary group vector, check it first.
-    for (i = 0; i < user_ngroups; i++) {
-	if (grp->gr_gid == user_groups[i])
-	    return(TRUE);
+    if (strcmp(user, user_name) == 0) {
+	for (i = 0; i < user_ngroups; i++) {
+	    if (grp->gr_gid == user_groups[i])
+		return(TRUE);
+	}
     if (grp->gr_mem != NULL) {

 	for (cur = grp->gr_mem; *cur; cur++) {

Now I ask : is it the C language really useless?


Entry filed under: linux, security, software. Tags: .

CMax Bug? Clonezilla : the cloning utility

3 Comments Add your own

  • 1. Giancarlo  |  18 February 2009 at 12:38 pm

    C is not obsolete, and University must teach computer programming, it not teach the cool language of the day.
    If you know computer programming you know how to use any programming language, but it is difficult to tell students.

    Excuse me for my horrible english 🙂

  • 2. nexthing  |  18 February 2009 at 4:22 pm

    You’re right!

  • 3. pimple  |  16 August 2010 at 7:08 pm

    Effort required to handle the complexity of c is repaid by his performance. When vb6 will be performing as c, we’ll make a comparison =)


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

Trackback this post  |  Subscribe to the comments via RSS Feed

Recent Posts

Visitors to this site

Top Clicks

  • None

%d bloggers like this: